Łukasz Magiera
1c055fe83b
Merge branch 'master' into test/t.TempDir
2022-03-17 12:06:52 +01:00
Darko Brdareski
79453663b3
feat: Add additional test annotations ( #8272 )
...
* Annotate api,proxy_util,blockstore_badger, policy tests
* Annotate splitstore: bsbadger / markset
* Annotate splitstore feature
* Annotate union/timed blockstore tests
* Annotate openrpc, diff_adt tests
* Annotate error,drand,events tests
* Annotate predicates_test
* Fix annotations
* Annotate tscache, gen tests
* Annotate fundmanager test
* Annotate repub and selection tests
* Annotate statetree_test
* Annotate forks_test
* Annotate searchwait_test.go
* Fix duplicated @@ symbols
* Annotate chain stmgr/store tests
* Annotate more (types) tests
* More tests annotated
* Annotate conformance chaos actor tests
* Annotate more integration tests
* Annotate journal system tests
* Annotate more tests.
* Annotate gas,head buffer behaviors
* Fix markset annotations
* doc: test annotations for the markets dagstore wrapper
* Annotate miner_api test in dagstore
* Annotate more test files
* Remove bad annotations from fsrepo
* Annotate wdpost system
* Remove bad annotations
* Renamce "conformance" to "chaos_actor" tests
* doc: stm annotations for blockheader & election proof tests
* Annotate remaining "A" tests
* annotate: stm for error_test
* memrepo_test.go
* Annotate "b" file tests
* message_test.go
* doc: stm annotate for fsrepo_test
* Annotate "c" file tests
* Annotate "D" test files
* message_test.go
* doc: stm annotate for chain, node/config & client
* docs: stm annotate node_test
* Annotate u,v,wl tests
* doc: stm annotations for various test files
* Annotate "T" test files
* doc: stm annotate for proxy_util_test & policy_test
* doc: stm annotate for various tests
* doc: final few stm annotations
* Add mempool unit tests
* Add two more memPool Add tests
* Update submodules
* Add check function tests
* Add stm annotations, refactor test helper
* Annotate api,proxy_util,blockstore_badger, policy tests
* Annotate splitstore: bsbadger / markset
solving merge conflicts
* Annotate splitstore feature
* Annotate union/timed blockstore tests
* Annotate openrpc, diff_adt tests
* Annotate error,drand,events tests
* Annotate predicates_test
* Fix annotations
* Annotate tscache, gen tests
* Annotate fundmanager test
* Annotate statetree_test
* Annotate forks_test
* Annotate searchwait_test.go
* Fix duplicated @@ symbols
* Annotate chain stmgr/store tests
* Annotate more (types) tests
* More tests annotated
* Annotate conformance chaos actor tests
* Annotate more integration tests
* Annotate journal system tests
* Annotate more tests.
* Annotate gas,head buffer behaviors
solve merge conflict
* Fix markset annotations
* Annotate miner_api test in dagstore
* Annotate more test files
* doc: test annotations for the markets dagstore wrapper
* Annotate wdpost system
* Renamce "conformance" to "chaos_actor" tests
* Annotate remaining "A" tests
* doc: stm annotations for blockheader & election proof tests
* annotate: stm for error_test
* Annotate "b" file tests
* memrepo_test.go
* Annotate "c" file tests
* message_test.go
* Annotate "D" test files
* doc: stm annotate for fsrepo_test
* Annotate u,v,wl tests
* message_test.go
* doc: stm annotate for chain, node/config & client
* docs: stm annotate node_test
* Annotate "T" test files
* doc: stm annotations for various test files
* Add mempool unit tests
solve merge conflict
* doc: stm annotate for proxy_util_test & policy_test
* doc: stm annotate for various tests
* doc: final few stm annotations
* Add two more memPool Add tests
* Update submodules
* Add check function tests
solve conflict
* Add stm annotations, refactor test helper
solve merge conflict
* Change CLI test kinds to "unit"
* Fix double merged test
* Fix ccupgrade_test merge
* Fix lint issues
* Add stm annotation to types_Test
* Test vectors submodule
* Add file annotation to burn_test
Co-authored-by: Nikola Divic <divicnikola@gmail.com>
Co-authored-by: TheMenko <themenkoprojects@gmail.com>
2022-03-16 18:37:34 +01:00
Eng Zer Jun
c229842f57
test: use T.TempDir
to create temporary test directory
...
The directory created by `T.TempDir` is automatically removed when the
test and all its subtests complete.
Reference: https://pkg.go.dev/testing#T.TempDir
Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2022-03-15 00:21:31 +08:00
vyzo
976a3a5e7b
fix blockstore test contexts
2021-12-17 13:44:05 +02:00
vyzo
dd327f0b22
plumb more contexts
2021-12-17 11:42:09 +02:00
Aayush Rajasekaran
dfb65ed89f
Plumb contexts through
2021-12-11 17:04:00 -05:00
whyrusleeping
072297e661
WIP: updating to new datastore/blockstore code with contexts
2021-12-09 14:12:25 +02:00
vyzo
5e8b2c7860
make symlink helper freestanding
2021-07-29 08:35:53 +03:00
vyzo
b75ff37448
fix typo
...
Co-authored-by: Jakub Sztandera <kubuxu@protocol.ai>
2021-07-28 17:11:04 +03:00
vyzo
c65d72fbca
fix format specifier
2021-07-28 16:20:25 +03:00
vyzo
fff1c0ae57
improve detection of relative links
2021-07-28 16:15:39 +03:00
vyzo
297c9e2f7a
extend test to check the validity of relative links
2021-07-28 11:56:35 +03:00
vyzo
0740274b7c
make relative links when the canonical and new db paths are in the same directory
2021-07-28 11:56:23 +03:00
vyzo
950ded454d
code cosmetics: rename variables for better readability and some comments
2021-07-28 11:49:42 +03:00
vyzo
c21c413695
remove db2 to dbNext
2021-07-27 12:06:40 +03:00
vyzo
bb2d99908c
make state constants typed
2021-07-27 12:03:26 +03:00
vyzo
b82f953fd5
use the badger streaming interface in doCopy
2021-07-27 11:46:35 +03:00
vyzo
59aebba0d9
use a slab allocator for the copy
2021-07-27 11:35:21 +03:00
vyzo
0baeec0686
remove filter from doCopy; it's not used
...
it was there to support a potential CopyTo interface; but we'll cross that bridge when we get there.
2021-07-27 11:18:24 +03:00
vyzo
649fc62863
panic if we fail to correctly setup the db paths.
...
we can't really continue and leave a ticking bomb for the next restart; the user might not see it.
2021-07-27 10:27:16 +03:00
vyzo
d6ace68540
extend test to do a double move and check symlink following
2021-07-27 10:16:50 +03:00
vyzo
cbaffab9dd
use EvalSymlinks in deleteDB
2021-07-27 10:08:07 +03:00
vyzo
c03859c1b5
resolve symlinks when constructing the new db path
...
so that the new path is adjacent to the old path, allowing the user to symlink the db in
a different file system.
2021-07-27 10:05:35 +03:00
vyzo
96c1123c33
use functional options in the BlockstoreGC interface
2021-07-27 09:52:06 +03:00
vyzo
938330e6c3
moveMx is not an RWMutex, just a regular mutex
2021-07-26 15:09:31 +03:00
vyzo
21e7c188da
use CollectGarbage in blockstore move test, as it is the real interface
2021-07-26 15:05:57 +03:00
vyzo
c747f2f1e2
do moving GC if the user asks for it
2021-07-26 15:05:57 +03:00
vyzo
a843665132
add options to BlockstoreGC trait
2021-07-26 15:05:57 +03:00
vyzo
94509968a0
make moveTo a private method
2021-07-26 15:05:20 +03:00
vyzo
5cf6fdf81d
don't heap allocate the cond, just set L
2021-07-26 15:04:46 +03:00
vyzo
524564e2cf
add some more logging around move
2021-07-26 15:04:46 +03:00
vyzo
f2c7b08be5
follow symbolic links when deleting old dbs
2021-07-26 15:04:46 +03:00
vyzo
608a9f84d2
fix copy: flush discards the transaction
2021-07-26 15:04:46 +03:00
vyzo
4b0b37a4ef
fix lint
...
the great spellchecker strikes again
2021-07-26 15:04:46 +03:00
vyzo
4715b1f436
fix lotus-shed
2021-07-26 15:04:46 +03:00
vyzo
aec126879e
add MoveTo test
2021-07-26 15:04:46 +03:00
vyzo
001c04f2dd
use pooled slices for the copy
2021-07-26 15:04:46 +03:00
vyzo
b741d61b20
implement BlockstoreMover in badger
2021-07-26 15:04:46 +03:00
vyzo
2cfd73c879
manually compute size when badger is being stupid
2021-07-26 09:46:21 +03:00
vyzo
30e4b405b7
implement BlockstoreSize for badger
2021-07-26 08:43:09 +03:00
vyzo
c93328b036
use the new traits for hotstore gc
2021-07-14 22:59:52 +03:00
vyzo
35180b4761
merge Compact and CollectGarbage in badger
2021-07-14 22:59:52 +03:00
vyzo
909f7039d4
make badger Close-safe
2021-07-09 09:54:12 +03:00
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