Tombstone must append before dropping the key from the index - #15
Open
paulocsanz wants to merge 2 commits into
Open
Tombstone must append before dropping the key from the index#15paulocsanz wants to merge 2 commits into
paulocsanz wants to merge 2 commits into
Conversation
index.remove before append means ENOSPC leaves the key gone in RAM. Retry returns Ok(None) and never writes a tombstone; reopen replays the PUT.
A failed disk write left the key gone in RAM, so retry returned Ok(None) and never wrote a record. Reopen replayed the PUT. Same order as put_full: durable first, then the index.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
tombstone/tombstone_condremoved the key from the index and then appended. ENOSPC (or any append error) left RAM empty and disk without a tombstone. Retry returnedOk(None)— "already deleted" — so GET-of-expired (the hot path) never retried the write. Reopen replayed the PUT and the key came back.put_fullalready appends first. Same order here. Stripe lock still serializes the key.Two commits: failing ENOSPC test, then append-then-remove.