Commit Graph

384 Commits

Author SHA1 Message Date
Raúl Kripalani
b1b452bc0f remove dependency from blockstore/splitstore => chain/store. 2021-03-05 14:46:18 +02:00
Raúl Kripalani
1a804fbdec move splitstore into blockstore package. 2021-03-05 14:46:18 +02:00
Raúl Kripalani
1b51c10d78 split off lmdb support to a different branch. 2021-03-05 14:46:18 +02:00
vyzo
0fc2f3a26f fix post-rebase compilation errors 2021-03-05 14:46:18 +02:00
vyzo
3282f856ec fix tests 2021-03-05 14:46:18 +02:00
vyzo
99c6e4f48f adjust min bloom filter size 2021-03-05 14:46:18 +02:00
vyzo
cae5ddce88 dynamically size bloom filters 2021-03-05 14:46:18 +02:00
vyzo
5639261e44 make compaction parameters variable 2021-03-05 14:46:18 +02:00
vyzo
7587ab6234 quiet the stupid linter 2021-03-05 14:46:18 +02:00
vyzo
05fee27840 remove stale references to lmdb from splitstore implementation 2021-03-05 14:46:18 +02:00
vyzo
f62999d2b8 use named constants for bloom filter parameters 2021-03-05 14:46:18 +02:00
vyzo
44aadb931a rehash salted keys in bloom filter 2021-03-05 14:46:17 +02:00
vyzo
88849201ff fix tests 2021-03-05 14:46:17 +02:00
vyzo
f5ce7957f3 size bloom filter for 50M objects 2021-03-05 14:46:17 +02:00
vyzo
f4c6bc6a86 comment nomenclature 2021-03-05 14:46:17 +02:00
vyzo
4cc672d0c5 batch move objects from coldstore to hotstore 2021-03-05 14:46:17 +02:00
vyzo
97abbe1eca add (salted) bloom filter liveset 2021-03-05 14:46:17 +02:00
vyzo
aba6530411 batch deletion for purging the tracking store 2021-03-05 14:46:17 +02:00
vyzo
09cd1175a1 structured log for beginning of compaction 2021-03-05 14:46:17 +02:00
vyzo
e52c709d8a more accurate setting of skip params 2021-03-05 14:46:17 +02:00
vyzo
2426ffb277 better logging plus moving some code around 2021-03-05 14:46:17 +02:00
vyzo
2f26026991 compactSimple should walk the cold epoch at depth 1
So that it finds reachable objects that should stay in the hotstore
2021-03-05 14:46:17 +02:00
vyzo
783dcda19c add Sync to the tracking store 2021-03-05 14:46:17 +02:00
vyzo
364076c1ea set NoSync option for bolt livesets 2021-03-05 14:46:17 +02:00
vyzo
73259aa350 add configuration for splitstore and default to a simple compaction algorithm 2021-03-05 14:46:17 +02:00
vyzo
2e4d45ef07 test for bolt backed tracking store 2021-03-05 14:46:17 +02:00
vyzo
f1c61c4753 implement bolt backed tracking store 2021-03-05 14:46:17 +02:00
vyzo
2c1a9781cf add test for bolt liveset 2021-03-05 14:46:17 +02:00
vyzo
27a9b974db implement bolt-backed liveset 2021-03-05 14:46:17 +02:00
vyzo
68b6f913c7 propagate useLMDB option to splitstore through DI 2021-03-05 14:46:17 +02:00
vyzo
923a3db4b0 abstract tracking store and live set construction 2021-03-05 14:46:17 +02:00
vyzo
8f0ddac41a add comment 2021-03-05 14:46:17 +02:00
vyzo
e79445123f handle MDB_KEY_EXIST in tracking store Puts 2021-03-05 14:46:17 +02:00
vyzo
9977f5c3ec rewrite sweep logic to avoid doing writes/deletes nested in a read txn 2021-03-05 14:46:17 +02:00
vyzo
ee751f88cd refactor lmdb specific snoop/liveset code into their own files
paves the way for different back ends
2021-03-05 14:46:17 +02:00
vyzo
8e12377e69 handle consistency edge case 2021-03-05 14:46:17 +02:00
vyzo
31268ba685 walk snapshot the same way snapshot exporting does; skip old msgs and receipts by default.
so that we don't panic with missing blocks in non-archival nodes
2021-03-05 14:46:17 +02:00
vyzo
5068d51ac3 use CompactionCold epochs for delinating the cold epoch cliff
this allows us to change the thresholds for testing.
2021-03-05 14:46:17 +02:00
vyzo
d44719dbd3 amend confusing comment 2021-03-05 14:46:17 +02:00
vyzo
842ec43c2f get rid of goroutine iteration in tracking store; long live ForEach 2021-03-05 14:46:17 +02:00
vyzo
a586d42c3b make hot store DI injectable in the split store, default to badger. 2021-03-05 14:46:17 +02:00
vyzo
7044e623f9 flag to enable GC during compaction, disabled for now 2021-03-05 14:46:17 +02:00
vyzo
f6c930d0aa crank up blockstore max readers to 16K, reduce retry delays to 10us 2021-03-05 14:46:17 +02:00
vyzo
95befa1e41 set lmdb max readers retry delay to 1ms 2021-03-05 14:46:17 +02:00
vyzo
874ecd3573 adjust hot store options, redux. 2021-03-05 14:46:17 +02:00
vyzo
ca8a673b5f adjust hot store options 2021-03-05 14:46:17 +02:00
vyzo
69a88d41b6 fix snoop test 2021-03-05 14:46:17 +02:00
vyzo
cdf5bd0500 return annotated xerrors where appropriate 2021-03-05 14:46:17 +02:00
vyzo
ea05fd9d86 use xerrors instead of fmt.Errorf 2021-03-05 14:46:17 +02:00
vyzo
d91b60df91 fix potential panic with max readers retry and cursor channel 2021-03-05 14:46:17 +02:00