Repository navigation
Conversation
This branch has not been deployed
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.
Fixes #7303
What and why
The unified prefix-affinity and session-order writers catch a failed snapshot read and proceed as if the row were absent. A successful subsequent write can then replace another process's durable chains or order skeletons with only this process's local view. The same failure occurs during legacy migration at startup.
Let rejected reads reach each writer's existing outer failure handler before merging, importing or publishing any replacement. Hydration remains retryable; a failed steady-state merge selects the documented legacy path for later writes. Affinity hydration reads content and presence from the same result, eliminating its separate presence probe while preserving existing present/missing semantics.
Validation
getKvAsync()rejects; all other reads/writes are real. Both hydration and later flush delete peer-only snapshot entries on the base, and all four fail there.npm run typecheck,npm run buildincluding both dist guards, the unused-export and test-import-graph checks, andgit diff --checkpass.Validation used Linux / Node.js 24.22.3 against
6453feeeb842bd1e471d875bf00287e5036a96c7(0.1.216), with both standard isolation preloads. The full repository regression verdict remains remote CI on this PR's head.Scope and boundaries
This is one failure-handling correction across the two snapshot carriers. It adds no configuration, format, kernel or wire change. It does not make cross-process read/merge/write atomic, and it does not claim that the failed flush immediately persists its local update: the existing failure policy switches subsequent writes to the legacy carrier.
#6186 fixed the async write lifecycle, #6477 fixes capacity accounting, and #5480 implements legacy journals. Their changes do not prevent this unified-read failure from authorizing an overwrite.