Commit Graph

15927 Commits

Author SHA1 Message Date
Steve Atherton 82a9bdbbaf
Merge pull request #4937 from apple/anoyes/allow-flow-lock-kill-to-delete-self
Allow FlowLock::kill to delete self
2021-06-09 12:31:31 -07:00
Andrew Noyes 74c6d2fda5 Allow FlowLock::kill to delete self
Calling broken_on_destruct.sendError() calls arbitrary callbacks, which
might delete the FlowLock. It's more robust to copy to a local variable
before sending.
2021-06-09 12:27:07 -07:00
sfc-gh-tclinkenbeard 399c2c96f0 Remove unnecessary std::string copies from flow 2021-06-09 11:40:01 -07:00
Josh Slocum c6d96c4124 Added TSS Quarantine and fixed TSS mapping bug in CommitProxy 2021-06-09 14:42:50 +00:00
Steve Atherton 23d27663c0 Merge commit '98e463d642d1e674983842c8b2925981ff849729' into redwood-deltatree2-master
# Conflicts:
#	fdbserver/IPager.h
#	fdbserver/Knobs.cpp
#	fdbserver/Knobs.h
#	fdbserver/VersionedBTree.actor.cpp
2021-06-09 01:31:16 -07:00
Steve Atherton 98e463d642
Merge pull request #4781 from sfc-gh-ngoyal/redwood_queue_improvements
Redwood queue format refactored to support faster cold start recovery of pager update log.
2021-06-09 00:11:57 -07:00
negoyal 78e1684d30 Minor review comments. 2021-06-08 22:04:01 -07:00
Chaoguang Lin 1f7acc8d02 Merge branch 'master' of github.com:apple/foundationdb into refactor-fdbcli-2 2021-06-09 02:29:18 +00:00
Steve Atherton 64429097bf Bump pager and btree format versions because there have been format changes. 2021-06-08 18:56:18 -07:00
negoyal 61252ef575 Revert the experimental change. 2021-06-08 18:20:20 -07:00
Steve Atherton b39d4af91a Redwood KVS wrapper now shares the same error Promise as the Pager, so the FlowLock in the read actors no longer needs to be reference counted. 2021-06-08 17:58:38 -07:00
Andrew Noyes b92b930b93 Add exportLibrary for exporting external clients from jar
After this change, users would be able to add all fdb shared libraries
they need in the jar itself with something like `jar uf`.
2021-06-08 17:23:02 -07:00
Steve Atherton f7554b8fcb Move FlowMutex unit test to FlowTests. 2021-06-08 16:58:35 -07:00
Steve Atherton adcf126bfa Removed commit read FlowLock because it costs too much overhead, will need another way to throttle. Removed readPage() fromCache argument as it is no longer useful. 2021-06-08 16:58:35 -07:00
Steve Atherton 293559bb61 Moved FlowMutex to genericactors. 2021-06-08 16:58:35 -07:00
Steve Atherton 72e077e69b Remove obsolete knobs. 2021-06-08 16:58:35 -07:00
Steve Atherton d94929f08d Added FlowMutex, a low overhead replacement for FlowLocks with a budget of 1. Replaced mutex in FIFOQueue::Cursor with FlowMutex to reduce overhead. 2021-06-08 16:58:35 -07:00
Steve Atherton 46c4f6fd47 Added yields to prevent stack overflows from too many callbacks when queue operations accumulate waiting on IO. 2021-06-08 16:58:35 -07:00
Steve Atherton 3af0bea46c Removed or reduced several yields because they are called too often. 2021-06-08 16:58:35 -07:00
Steve Atherton f2904dadf3 Reading BTree pages no longer requires boundary records, as they are not needed if the page is already cached. 2021-06-08 16:58:35 -07:00
Steve Atherton a485ae1215 Log pagerMemoryOnly in test config. 2021-06-08 16:58:35 -07:00
Steve Atherton b4c446bc8b Remove unused variable. 2021-06-08 16:58:35 -07:00
Steve Atherton 345a484ce7 Prevent rehashing by reserving cache size limit in cache map. 2021-06-08 16:58:35 -07:00
Steve Atherton f95d592db8 Optimized record delta decoding / applying a bit, changed substring order to (value, keySuffix) since value is needed more frequently. Added DeltaTree2 item type requirement to create T from base's cached partial item instead of full record. 2021-06-08 16:58:35 -07:00
Steve Atherton b8af2950c8 Remove some leftover Version field remnants, update RedwoodRecordRef comments. 2021-06-08 16:58:35 -07:00
Steve Atherton 3451c2242f DeltaTree2::Cursor now reconstructs current item on-demand, caches it in an Optional member, and does not initialize it when a cursor is copied. 2021-06-08 16:58:35 -07:00
Steve Atherton 7f411934b4 Rare simulation-only bug fix. A single-page BTree with too small of a page size and one gigantic value can result in a root page list that is too large to fit in the hardcoded MetaKey size. 2021-06-08 16:58:32 -07:00
Steve Atherton 0c94a25c48 Prioritized cache eviction of old page versions and freed pages. 2021-06-08 16:55:30 -07:00
Steve Atherton 6cc7845856 Restore non-caching reads on the commit path, probably temporarily, to remove this as a variable before/after the switch to DeltaTree2. 2021-06-08 16:55:30 -07:00
Steve Atherton 96f14a714f Fixed memory leak, DecodeCache reference count was initialized incorrectly. Streamlined perf unit test a bit. 2021-06-08 16:55:30 -07:00
Steve Atherton fa7a73071f Fixed memory leak, InternalPageSliceUpdates require destruction. 2021-06-08 16:55:30 -07:00
Steve Atherton 9c7ec8d6cd Removed RedwoodRecordRef::version since in the current design all record versions within a single BTree snapshot are the same. 2021-06-08 16:55:20 -07:00
Xiaoxi Wang 51b4cb89c2 fix server_status bug 2021-06-08 23:47:59 +00:00
Steve Atherton 4ee27919ad Print size of RedwoodRecordRef in unit test. 2021-06-08 16:46:09 -07:00
Steve Atherton e2c3d2d108 Removed redundant calls to Cursor::switchTree() since there are no cases where the it matters if get() references the old tree's value until the cursor is moved. 2021-06-08 16:46:09 -07:00
Steve Atherton a9cf0a2471 Removed unnecessary cursor member from InternalPageModifier. Changed BTreePage::tree() methods to return a pointer instead of a reference since >90% of usages want a pointer. 2021-06-08 16:46:09 -07:00
Steve Atherton 751bac2271 Write path no longer uses non-caching reads because it is no longer necessary to avoid a page copy. Page copies are only done just before an actual change is made. 2021-06-08 16:46:09 -07:00
Steve Atherton 8e7a97f495 Bug fix: BTreeCursor::init() did not clear path. 2021-06-08 16:46:09 -07:00
Steve Atherton a58ac622ed Bug fix in test data generation for IntIntPair DeltaTree unit test. 2021-06-08 16:46:09 -07:00
Steve Atherton a6f7d37a25 Bug fixes related to DeltaTree2::Cursor contract being different from DeltaTree::Cursor. 2021-06-08 16:46:09 -07:00
Steve Atherton 8ef516ead2 Bug fixes from bad search/replace. DeltaTree2::Cursor now keeps current decoded item as a member instead of calculating it on demand in get(). 2021-06-08 16:46:09 -07:00
Steve Atherton d155482f5f Remove the legacy IVersionedStore / IStoreCursor classes and implementations as they are no longer useful or efficient, respectively. BTreeCursor can be used far more efficiently to access the BTree. 2021-06-08 16:46:09 -07:00
Steve Atherton 1d947bff2d Initial pass at getting BTree to compile with DeltaTree2. Does not work since the Cursor contract has changed. 2021-06-08 16:46:09 -07:00
Steve Atherton d208d3f3ec Bug fixes, moveFirst/Last didn't handle tree size of 1 correctly. 2021-06-08 16:46:09 -07:00
Steve Atherton 65cfd31221 Added memory-only option for redwood set test. 2021-06-08 16:46:09 -07:00
Steve Atherton caf4b3c345 DeltaTree2 refactor. Nodes no longer contain parent offsets. DecodedCache no longer uses a hash but rather a vector of DecodedNodes, which Cursors reference by vector index. DecodedNodes contain parent node indexes which are populated on-demand, making storage in the serialized form no longer necessary. 2021-06-08 16:46:04 -07:00
Xiaoxi Wang 45ebdb1a9d fix perpetual wiggle bug caused by multiple DCs and removeStorageServer 2021-06-08 23:33:25 +00:00
Steve Atherton b0ec76d401 Test output improvements. 2021-06-08 15:32:54 -07:00
Steve Atherton 9ab69b5cb1 RedwoodRecordRef support for DeltaTree2. 2021-06-08 15:32:54 -07:00
Steve Atherton 701f05e513 Bug fix, recursive call to get() could cause rehashing so hash lookup must be redone afterward. 2021-06-08 15:32:54 -07:00