Skip to content

sqlite: increase retries #399

sqlite: increase retries

sqlite: increase retries #399

Triggered via push August 1, 2023 22:00
Status Failure
Total duration 5m 33s
Artifacts

publish.yml

on: push
Fit to window
Zoom out
Zoom in

Annotations

10 errors
test
2/61 tests failed
Test go.sia.tech/hostd/persist/sqlite/TestTransactionRetry failed in 19.36s: persist/sqlite/logger.go#L130
logger.go:130: 2023-08-01T22:05:20.064Z DEBUG transaction slow exec {"attempt": 1, "query": "/*\n\tWhen changing the schema, the version must be incremented at the bottom of\n\tthis file and a migration added to migrations.go\n*/\n\nCREATE TABLE wallet_utxos (\n\tid BLOB PRIMARY KEY,\n\tamount BLOB NOT NULL,\n\tunlock_hash BLOB NOT NULL\n);\n\nCREATE TABLE wallet_transactions (\n\tid INTEGER PRIMARY KEY,\n\ttransaction_id BLOB NOT NULL,\n\tblock_id BLOB NOT NULL,\n\tinflow BLOB NOT NULL,\n\toutflow BLOB NOT NULL,\n\traw_transaction BLOB NOT NULL, -- binary serialized transaction\n\tsource TEXT NOT NULL,\n\tblock_height INTEGER NOT NULL,\n\tdate_created INTEGER NOT NULL\n);\nCREATE INDEX wallet_transactions_date_created_index ON wallet_transactions(date_created);\nCREATE INDEX wallet_transactions_block_id ON wallet_transactions(block_id);\nCREATE INDEX wallet_transactions_date_created ON wallet_transactions(date_created);\nCREATE INDEX wallet_transactions_block_height_id ON wallet_transactions(block_height DESC, id);\n\nCREATE TABLE stored_sectors (\n\tid INTEGER PRIMARY KEY,\n\tsector_root BLOB UNIQUE NOT NULL,\n\tlast_access_timestamp INTEGER NOT NULL\n);\nCREATE INDEX stored_sectors_sector_root ON stored_sectors(sector_root);\nCREATE INDEX stored_sectors_last_access ON stored_sectors(last_access_timestamp);\n\nCREATE TABLE storage_volumes (\n\tid INTEGER PRIMARY KEY,\n\tdisk_path TEXT UNIQUE NOT NULL,\n\tused_sectors INTEGER NOT NULL,\n\ttotal_sectors INTEGER NOT NULL,\n\tread_only BOOLEAN NOT NULL,\n\tavailable BOOLEAN NOT NULL DEFAULT false\n);\nCREATE INDEX storage_volumes_read_only_available ON storage_volumes(read_only, available);\n\nCREATE TABLE volume_sectors (\n\tid INTEGER PRIMARY KEY,\n\tvolume_id INTEGER NOT NULL REFERENCES storage_volumes (id), -- all sectors will need to be migrated first when deleting a volume\n\tvolume_index INTEGER NOT NULL,\n\tsector_id INTEGER UNIQUE REFERENCES stored_sectors (id),\n\tUNIQUE (volume_id, volume_index)\n);\n-- careful with these indices, the empty sector query is fragile and relies on\n-- the volume_index indice for performance.\nCREATE INDEX volume_sectors_volume_id ON volume_sectors(volume_id);\nCREATE INDEX volume_sectors_volume_index ON volume_sectors(volume_index ASC);\nCREATE INDEX volume_sectors_sector_id ON volume_sectors(sector_id);\n\nCREATE TABLE locked_volume_sectors ( -- should be cleared at startup. currently persisted for simplicity, but may be moved to memory\n\tid INTEGER PRIMARY KEY,\n\tvolume_sector_id INTEGER REFERENCES volume_sectors(id) ON DELETE CASCADE\n);\nCREATE INDEX locked_volume_sectors_sector_id ON locked_volume_sectors(volume_sector_id);\n\nCREATE TABLE contract_renters (\n\tid INTEGER PRIMARY KEY,\n\tpublic_key BLOB UNIQUE NOT NULL\n);\n\nCREATE TABLE contracts (\n\tid INTEGER PRIMARY KEY,\n\trenter_id INTEGER NOT NULL REFERENCES contract_renters(id),\n\trenewed_to INTEGER REFERENCES contracts(id) ON DELETE SET NULL,\n\trenewed_from INTEGER REFERENCES contracts(id) ON DELETE SET NULL,\n\tcontract_id BLOB UNIQUE NOT NULL,\n\trevision_number BLOB NOT NULL, -- stored as BLOB to support uint64_max on clearing revisions\n\tformation_txn_set BLOB NOT NULL, -- binary serialized transaction set\n\tlocked_collateral BLOB NOT NULL,\n\trpc_revenue BLOB NOT NULL,\n\tstorage_revenue BLOB NOT NULL,\n\tingress_revenue BLOB NOT NULL,\n\tegress_revenue BLOB NOT NULL,\n\taccount_funding BLOB NOT NULL,\n\trisked_collateral BLOB NOT NULL,\n\tconfirmed_revision_number BLOB, -- stored as BLOB to support uint64_max on clearing revisions\n\thost_sig BLOB NOT NULL,\n\trenter_sig BLOB NOT NULL,\n\traw_revision BLOB NOT NULL, -- binary serialized contract revision\n\tformation_confirmed BOOLEAN NOT NULL, -- true if the contract has been confirmed on the blockchain\n\tresolution_height INTEGER, -- null if the storage proof/resolution has not been confirmed on the blockchain, otherwise the height of the block containing the storage proof/resolution\n\tnegotiation_height INTEGER NOT NULL, -- determines if the formation txn should be rebroadcast or if the contract sho
Test go.sia.tech/hostd/persist/sqlite/TestTransactionRetry failed in 19.36s: persist/sqlite/sql.go#L144
;\n\nCREATE TABLE global_settings (\n\tid INTEGER PRIMARY KEY NOT NULL DEFAULT 0 CHECK (id = 0), -- enforce a single row\n\tdb_version INTEGER NOT NULL, -- used for migrations\n\thost_key BLOB,\n\twallet_hash BLOB, -- used to prevent wallet seed changes\n\twallet_last_processed_change BLOB, -- last processed consensus change for the wallet\n\tcontracts_last_processed_change BLOB, -- last processed consensus change for the contract manager\n\twallet_height INTEGER, -- height of the wallet as of the last processed change\n\tcontracts_height INTEGER -- height of the contract manager as of the last processed change\n);\n\nINSERT INTO global_settings (id, db_version) VALUES (0, 10); -- version must be updated when the schema changes", "elapsed": "4.061473ms", "stack": "go.sia.tech/hostd/persist/sqlite.(*loggedTxn).Exec\n\t/home/runner/work/hostd/hostd/persist/sqlite/sql.go:144\ngo.sia.tech/hostd/persist/sqlite.(*Store).init.func1\n\t/home/runner/work/hostd/hostd/persist/sqlite/init.go:36\ngo.sia.tech/hostd/persist
Test go.sia.tech/hostd/persist/sqlite/TestTransactionRetry failed in 19.36s: persist/sqlite/store.go#L138
/sqlite.doTransaction\n\t/home/runner/work/hostd/hostd/persist/sqlite/store.go:138\ngo.sia.tech/hostd/persist/sqlite.(*Store).transaction\n\t/home/runner/work/hostd/hostd/persist/sqlite/store.go:89\ngo.sia.tech/hostd/persist/sqlite.(*Store).init\n\t/home/runner/work/hostd/hostd/persist/sqlite/init.go:31\ngo.sia.tech/hostd/persist/sqlite.OpenDatabase\n\t/home/runner/work/hostd/hostd/persist/sqlite/store.go:171\ngo.sia.tech/hostd/persist/sqlite.TestTransactionRetry\n\t/home/runner/work/hostd/hostd/persist/sqlite/store_test.go:15\ntesting.tRunner\n\t/opt/hostedtoolcache/go/1.20.6/x64/src/testing/testing.go:1576"}
Test go.sia.tech/hostd/persist/sqlite/TestTransactionRetry failed in 19.36s: persist/sqlite/logger.go#L130
logger.go:130: 2023-08-01T22:05:20.171Z DEBUG transaction slow exec {"attempt": 1, "query": "UPDATE global_settings SET host_key=?", "elapsed": "100.970033ms", "stack": "go.sia.tech/hostd/persist/sqlite.(*loggedTxn).Exec\n\t/home/runner/work/hostd/hostd/persist/sqlite/sql.go:144\ngo.sia.tech/hostd/persist/sqlite.TestTransactionRetry.func2.2\n\t/home/runner/work/hostd/hostd/persist/sqlite/store_test.go:50\ngo.sia.tech/hostd/persist/sqlite.doTransaction\n\t/home/runner/work/hostd/hostd/persist/sqlite/store.go:138\ngo.sia.tech/hostd/persist/sqlite.(*Store).transaction\n\t/home/runner/work/hostd/hostd/persist/sqlite/store.go:89\ngo.sia.tech/hostd/persist/sqlite.TestTransactionRetry.func2\n\t/home/runner/work/hostd/hostd/persist/sqlite/store_test.go:49\ntesting.tRunner\n\t/opt/hostedtoolcache/go/1.20.6/x64/src/testing/testing.go:1576"}
Test go.sia.tech/hostd/persist/sqlite/TestTransactionRetry failed in 19.36s: persist/sqlite/logger.go#L130
logger.go:130: 2023-08-01T22:05:20.172Z DEBUG transaction database locked {"attempt": 1, "elapsed": "102.209856ms", "stack": "go.sia.tech/hostd/persist/sqlite.(*Store).transaction\n\t/home/runner/work/hostd/hostd/persist/sqlite/store.go:100\ngo.sia.tech/hostd/persist/sqlite.TestTransactionRetry.func2\n\t/home/runner/work/hostd/hostd/persist/sqlite/store_test.go:49\ntesting.tRunner\n\t/opt/hostedtoolcache/go/1.20.6/x64/src/testing/testing.go:1576"}
Test go.sia.tech/hostd/persist/sqlite/TestTransactionRetry failed in 19.36s: persist/sqlite/logger.go#L130
logger.go:130: 2023-08-01T22:05:20.278Z DEBUG transaction slow exec {"attempt": 2, "query": "UPDATE global_settings SET host_key=?", "elapsed": "102.589063ms", "stack": "go.sia.tech/hostd/persist/sqlite.(*loggedTxn).Exec\n\t/home/runner/work/hostd/hostd/persist/sqlite/sql.go:144\ngo.sia.tech/hostd/persist/sqlite.TestTransactionRetry.func2.2\n\t/home/runner/work/hostd/hostd/persist/sqlite/store_test.go:50\ngo.sia.tech/hostd/persist/sqlite.doTransaction\n\t/home/runner/work/hostd/hostd/persist/sqlite/store.go:138\ngo.sia.tech/hostd/persist/sqlite.(*Store).transaction\n\t/home/runner/work/hostd/hostd/persist/sqlite/store.go:89\ngo.sia.tech/hostd/persist/sqlite.TestTransactionRetry.func2\n\t/home/runner/work/hostd/hostd/persist/sqlite/store_test.go:49\ntesting.tRunner\n\t/opt/hostedtoolcache/go/1.20.6/x64/src/testing/testing.go:1576"}
Test go.sia.tech/hostd/persist/sqlite/TestTransactionRetry failed in 19.36s: persist/sqlite/logger.go#L130
logger.go:130: 2023-08-01T22:05:20.278Z DEBUG transaction database locked {"attempt": 2, "elapsed": "102.99337ms", "stack": "go.sia.tech/hostd/persist/sqlite.(*Store).transaction\n\t/home/runner/work/hostd/hostd/persist/sqlite/store.go:100\ngo.sia.tech/hostd/persist/sqlite.TestTransactionRetry.func2\n\t/home/runner/work/hostd/hostd/persist/sqlite/store_test.go:49\ntesting.tRunner\n\t/opt/hostedtoolcache/go/1.20.6/x64/src/testing/testing.go:1576"}
Test go.sia.tech/hostd/persist/sqlite/TestTransactionRetry failed in 19.36s: persist/sqlite/logger.go#L130
logger.go:130: 2023-08-01T22:05:20.383Z DEBUG transaction slow exec {"attempt": 3, "query": "UPDATE global_settings SET host_key=?", "elapsed": "100.933133ms", "stack": "go.sia.tech/hostd/persist/sqlite.(*loggedTxn).Exec\n\t/home/runner/work/hostd/hostd/persist/sqlite/sql.go:144\ngo.sia.tech/hostd/persist/sqlite.TestTransactionRetry.func2.2\n\t/home/runner/work/hostd/hostd/persist/sqlite/store_test.go:50\ngo.sia.tech/hostd/persist/sqlite.doTransaction\n\t/home/runner/work/hostd/hostd/persist/sqlite/store.go:138\ngo.sia.tech/hostd/persist/sqlite.(*Store).transaction\n\t/home/runner/work/hostd/hostd/persist/sqlite/store.go:89\ngo.sia.tech/hostd/persist/sqlite.TestTransactionRetry.func2\n\t/home/runner/work/hostd/hostd/persist/sqlite/store_test.go:49\ntesting.tRunner\n\t/opt/hostedtoolcache/go/1.20.6/x64/src/testing/testing.go:1576"}