Commit Graph

14 Commits

Author SHA1 Message Date
Jakub Sztandera
80aa96ec25 Appease the linter
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2023-05-31 12:48:34 -04:00
Jakub Sztandera
b65c93b2b4 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-31 12:48:25 -04:00
Aayush
90c89288b6 feat: chain: make fetching tipset by height 1000x faster 2023-03-09 15:12:13 -05:00
Łukasz Magiera
e65fae28de chore: fix imports 2022-06-14 17:00:51 +02:00
Aayush Rajasekaran
dfb65ed89f Plumb contexts through 2021-12-11 17:04:00 -05:00
Aayush Rajasekaran
10b931312b Fix edgecase in tipset skipcache 2021-05-27 13:44:37 -04:00
Aayush Rajasekaran
39755a294a Update to specs v0.9.6 2020-09-07 15:48:41 -04:00
whyrusleeping
1fc768fb32 add env vars to configure chain store cache sizes 2020-08-11 15:07:17 -07:00
Raúl Kripalani
c8104a03e6
some initial godocs. (#2118) 2020-06-23 18:51:25 -03:00
Łukasz Magiera
8b308972a4 chainstore index: Drop wrong check 2020-06-11 15:43:24 +02:00
Jeromy
295c0861c4 fix chain index seeking through long ranges of null rounds 2020-06-10 22:15:46 -07:00
Aayush Rajasekaran
656b285195 Bugfix: Begin walkback when lookback target's height is too low 2020-06-04 18:17:54 -04:00
whyrusleeping
86083531c6 a couple bugfixes 2020-06-04 18:17:54 -04:00
Jeromy
c01f70105f implement chain index to make lookbacks faster 2020-06-04 18:17:54 -04:00