Commit Graph

64 Commits

Author SHA1 Message Date
vyzo
08cad30be2 reuse key buffer in badger ForEachKey
cid copies the bytes so it's safe
2021-07-04 18:38:28 +03:00
vyzo
d476a3db2c BlockstoreIterator trait with implementation for badger 2021-07-04 18:38:28 +03:00
Łukasz Magiera
5f80869fe0
Merge pull request #5794 from filecoin-project/fix/atomic-first
fix: make sure atomic 64bit fields are 64bit aligned
2021-03-25 13:29:59 +01:00
Łukasz Magiera
c69b26cfc6
Merge pull request #5778 from filecoin-project/feat/splitstore-compact-hotstore
splitstore: compact hotstore prior to garbage collection
2021-03-12 16:30:05 +01:00
Steven Allen
bba71da401 fix: return buffers after canceling badger operation
In theory, Delete/Put could fail. If it does, we'll return the buffers
to the pool before we're really done with them.

In practice, this is almost certainly not an issue as badger shouldn't
_use_ the buffer unless we flush. But I feel slightly safer this way.
2021-03-11 20:30:43 -08:00
Steven Allen
1c490f3fda fix: make sure atomic 64bit fields are 64bit aligned
Otherwise, this won't work on 32bit ARM.
2021-03-11 20:10:39 -08:00
vyzo
01ce9b5c44 add Compact to badger blockstore 2021-03-11 11:45:05 +02:00
vyzo
90741da019 tune badger gc to repeated gc the value log until there is no rewrite 2021-03-08 21:46:44 +02:00
vyzo
3d1b855f20 rename GC to CollectGarbage, ignore badger.ErrNoRewrite 2021-03-08 19:42:38 +02:00
vyzo
8562a9bb82 garbage collect hotstore after compaction 2021-03-08 18:12:09 +02:00
vyzo
86b73d651e add DeleteMany to Blockstore interface 2021-03-05 14:46:18 +02:00
Raúl Kripalani
b34b4e0374 fix test compilation error. 2021-02-28 23:10:01 +00:00
Raúl Kripalani
3795cc2bd2 segregate chain and state blockstores.
This paves the way for better object lifetime management.

Concretely, it makes it possible to:
- have different stores backing chain and state data.
- having the same datastore library, but using different parameters.
- attach different caching layers/policies to each class of data, e.g.
  sizing caches differently.
- specifying different retention policies for chain and state data.

This separation is important because:
- access patterns/frequency of chain and state data are different.
- state is derivable from chain, so one could never expunge the chain
  store, and only retain state objects reachable from the last finality
  in the state store.
2021-02-28 22:49:44 +00:00
Raúl Kripalani
b0cbc932bd consolidate all blockstores in blockstore package. 2021-01-29 20:01:00 +00:00