mirror of
https://github.com/syncthing/syncthing.git
synced 2024-11-16 18:41:59 -07:00
d7d45d8092
This removes a significant, complex chunk of database code. The "replace" operation walked both the old and new in lockstep and made the relevant changes to make the new situation correct. But since delta indexes we pretty much never need this - we just used replace to drop the existing data and start over. This makes that explicit and removes the complexity. (This is one of those things that would be annoying to make case insensitive, while the actual "drop and then insert" that we do is easier.) This is fairly well unit tested... The one change to the tests is to cover the fact that previously replace with something identical didn't bump the sequence number, while obviously removing everything and re-inserting does. This is not behavior we depend on anywhere. GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/4500 LGTM: imsodin, AudriusButkevicius |
||
---|---|---|
.. | ||
testdata | ||
.gitignore | ||
benchmark_test.go | ||
blockmap_test.go | ||
blockmap.go | ||
concurrency_test.go | ||
debug.go | ||
leveldb_dbinstance.go | ||
leveldb_test.go | ||
leveldb_transactions.go | ||
leveldb.go | ||
namespaced_test.go | ||
namespaced.go | ||
set_test.go | ||
set.go | ||
structs.go | ||
structs.pb.go | ||
structs.proto |