Record upsert snapshot outcomes and saved content fingerprints - #19515
Draft
KKcorps wants to merge 4 commits into
Draft
Record upsert snapshot outcomes and saved content fingerprints#19515KKcorps wants to merge 4 commits into
KKcorps wants to merge 4 commits into
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## master #19515 +/- ##
============================================
- Coverage 67.74% 67.74% -0.01%
- Complexity 1424 1450 +26
============================================
Files 3489 3495 +6
Lines 224672 225322 +650
Branches 35468 35603 +135
============================================
+ Hits 152210 152636 +426
- Misses 60445 60619 +174
- Partials 12017 12067 +50
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
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.
PR flow
Records snapshot outcomes and segment fingerprint metadata during upsert snapshots.
AI-generated · Green: added · Yellow: modified · Red: removed · Gray: existing
Diff evidence
Summary
An upsert snapshot can skip a segment lock, and a later successful attempt can hide that event. Saved bitmap counts can also match while their document memberships differ. This adds opt-in producer evidence for those two cases: snapshot outcomes and saved-content fingerprints.
The implementation follows four steps:
Cumulative counters are scoped to one manager runtime so a poller can observe earlier failures. Cleanup is immutable before/after data, with current cleanup exposed separately; concurrent snapshots have one explicit flag. There is no provisional lifecycle/configuration comparison machinery.
Scope and cost
upsertConfig.metadataManagerConfigs.enableSnapshotMetadatadefaults tofalse. No per-record hooks, key scans, extra bitmap serialization, blocking locks, or predecessor waits are added. Enabled captures pay for hashing, sorting/aggregation, two optional cached hashes per immutable segment, and synchronous compact sidecar publication.The payload does not grow with the segment inventory. Missing hashes remain unknown. Raw Roaring bytes are not canonical membership, so a mismatch requires logical bitmap comparison after binding fetched files to the target report.
boundaryStatusremainsUNVERIFIED; shared source-boundary attestation and controller comparison/alerts are follow-ups. Version 3 rejects earlier draft sidecars. Existing no-argument snapshot overrides and bitmap response constructors are preserved.Validation
git diff --checkpassed.ZstandardDecompressor.java:51:org.jetbrains.annotations.NotNullis absent from the zstd compilation classpath. No warning matched added lines before failure; this check is not claimed as passed.Release notes
Adds optional upsert snapshot outcome counters, saved-content fingerprints, and server APIs for diagnostics.
Related: #19499. Documentation:
docs/upsert-snapshot-metadata.md. RocksDB cleanup companion: startreedata/startree-pinot#4290.