Allow FullMergeV3 to produce a deletion result via std::monostate#14607
Open
zaidoon1 wants to merge 1 commit intofacebook:mainfrom
Open
Allow FullMergeV3 to produce a deletion result via std::monostate#14607zaidoon1 wants to merge 1 commit intofacebook:mainfrom
zaidoon1 wants to merge 1 commit intofacebook:mainfrom
Conversation
✅ clang-tidy: No findings on changed linesCompleted in 364.3s. |
d3c531c to
30c844c
Compare
Add std::monostate as a fourth alternative to MergeOperationOutputV3::NewValue. When a merge operator sets this variant, the key is treated as deleted: - Get()/MultiGet() return Status::NotFound() - Iterators skip the key (forward and backward) - Compaction produces a deletion tombstone, or drops the key entirely when the full history has been seen at the bottommost level This enables use cases like counter auto-delete-at-zero, conditional mutations, and Cassandra-style row expiration without requiring a separate compaction filter. Closes facebook#14593
30c844c to
f66c937
Compare
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.
Add std::monostate as a fourth alternative to
MergeOperationOutputV3::NewValue. When a merge operator sets this variant, the key is treated as deleted:
This enables use cases like counter auto-delete-at-zero, conditional mutations, and Cassandra-style row expiration without requiring a separate compaction filter.
Closes #14593