lotus/chain/store
Jakub Sztandera dfa7fc7723
feat: chainstore: sharded mutex for filling chain height index
This PR introduces as sharded mutex within the ChainIndex#GetTipsetByHeight.
It also replaces a go map with xsync.Map which doesn't require locking.

The lock is taken when it appears that ChainIndex filling work should be
started. After claiming the lock, the status of the cache is rechecked,
if the entry is still missing, the fillCache is started.

Thanks to @snissn and @arajasek for debugging and taking initial stabs at this.

Supersedes #10866 and 10885

Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2023-05-19 19:49:22 +02:00
..
basefee_test.go feat: support typed errors over RPC 2022-09-27 15:34:01 +00:00
basefee.go chore: fix imports 2022-06-14 17:00:51 +02:00
checkpoint_test.go fix make gen 2022-08-29 16:25:30 +02:00
coalescer_test.go fix make gen 2022-08-29 16:25:30 +02:00
coalescer.go fix make gen 2022-08-29 16:25:30 +02:00
fts.go chore: fix imports 2022-06-14 17:00:51 +02:00
index_test.go fix make gen 2022-08-29 16:25:30 +02:00
index.go feat: chainstore: sharded mutex for filling chain height index 2023-05-19 19:49:22 +02:00
messages.go chore: all: migrate from go-libipfs to boxo 2023-04-18 17:22:18 +02:00
snapshot.go feat: chainstore: batch writes of tipsets 2023-05-02 17:26:07 -04:00
store_test.go lint 2023-03-12 15:50:10 +02:00
store.go Check if epoch is negative in GetTipsetByHeight 2023-05-16 21:19:03 -04:00