Conversation
ragnorc
force-pushed
the
claude/rfc-0067-ensure-indices-detached
branch
from
September 17, 2026 07:01
de3afe6 to
74318a3
Compare
ragnorc
force-pushed
the
claude/rfc-0067-merge-detached
branch
from
September 17, 2026 07:01
e5f8069 to
c122211
Compare
…(RFC 0067 step 4) Every merged table's chunks now commit as detached versions chained on the pin captured before classification: the proven insertion chain, the adopted delta and the three-way rewrite each land one link per chunk within the existing transaction ceiling, the table's pin publishes the linear base plus the chain length with the tip as its staged version, and the writer promotes every link in order from the handles it holds. A pointer adoption copies the source's entry as it is, so a pending pin becomes the target's pin too; a first-touch fork on a named target is created under the gates with no intent record. No BranchMerge sidecar is armed, confirmed or deleted, and a merge that fails before publication returns its error and leaves only reclaimable garbage: the pre-minted identities, the exact-commit outcome check, the in-process compensation and the RecoveryRequired wrapping are gone. The mutation path's first-touch check accepts an inherited handle opened at a pending pin's staged version, which pointer adoption exposed. Seams branch_merge.post_sidecar_pre_fork, post_effects_pre_confirm and pre_error_recovery are gone; post_fork_pre_commit, post_table_effect and post_publish_pre_promotion name the new windows. The failure matrix gains the merge writer, the sidecar-era merge tests retire in favour of no-residue, pending-chain, CAS-loss, foreign-commit, first-touch and pointer-adoption tests, the recovery-machinery tests take their sidecar from Optimize, and the GQT known-failure fixture retires with the last corpus writer that could arm a recovery intent. The classifier keeps the BranchMerge kind until step 5.
…rs (RFC 0067) The detached branch merge arms, confirms and deletes no sidecar, so the `RecoveryArm`, `RecoveryConfirm` and `RecoveryCleanup` merge timing phases record nothing. The bench's phase topology treated an unentered `RecoveryArm` as a mismatch and failed three fixture merges in CI. The three phases leave the engine's `MergeTimingPhase`, its probe accessors and the rfc023 scenario, and the bench's stable and required phase tables and stored-sample fixture; the merge guide's timing chain follows.
… (RFC 0067) Seven `failpoints.rs` cases: the single-link pending-pin diff control, the blocked-chain and pending-merge diffs, cleanup on a blocked pin, the aged detached-manifest reaper, the reader racing a promotion, and a stale handle writing after another handle's promotion. The five that reproduced the review's defects failed before the fixes. The maintenance and write guides describe the blocked-pin GC refusal and the age-gated reaper, and the blocked-pin sentence now says branch merge and index maintenance stage behind a block.
ragnorc
force-pushed
the
claude/rfc-0067-ensure-indices-detached
branch
from
September 17, 2026 07:53
74318a3 to
7bba37d
Compare
ragnorc
force-pushed
the
claude/rfc-0067-merge-detached
branch
from
September 17, 2026 07:53
c122211 to
f3fcc96
Compare
Contributor
Author
|
Consolidated into #744, which carries this stack's complete history merged with current main and revalidated as one tree. |
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.
RFC 0067 rollout step 4, third writer: branch merge stages detached commits. Stacked on #733 (ensure-indices), which is stacked on #731, #728, #727 and #725.
What changes
prepare_existing_merge_targetopens the pin (open_pinned_for_write, promoting a pending predecessor first, staging behind a blocked one); each chunk of a proven insertion chain, an adopted delta or a three-way rewrite commits throughcommit_staged_detachedon the previous chunk (MergeChain, one link per chunk within the existingMAX_BRANCH_MERGE_DATA_TRANSACTIONSceiling, now checked byplan_merge_chain_length); the table's pin publishesexpected + chain lengthwith the tip as its staged version, in the one manifest commit. The writer then promotes every link in order (HeldPromotiongained achain, andpromote_heldreplays the links from the base, continuing from a twin a racing promoter landed).new_branch_merge_sidecar_v9iscfg(test),confirm_branch_merge_sidecar_v9andrecover_failed_branch_merge_under_gatesare deleted, the exact-commit outcome check and theRecoveryRequiredwrapping are gone; a merge that fails before publication returns its error and leaves only detached chains and unreferenced forks, which cleanup classifies. A first-touch fork on a named target is created under the gates with no intent record. Pointer adoption copies the source's entry as it is, so a pending pin becomes the target's pin too.branch_merge.post_sidecar_pre_fork,branch_merge.post_effects_pre_confirmandbranch_merge.pre_error_recoveryare gone;branch_merge.post_fork_pre_commit,branch_merge.post_table_effectandbranch_merge.post_publish_pre_promotionare new; the chunk seams andpost_authority_capture,post_candidate_validation,post_phase_b_pre_manifest_commitkeep their names.BranchMergekind for sidecars written before the change, as engine: mutation and load stage detached commits and publish pins (RFC 0067 step 4a) #731 and engine: ensure_indices and the full-text rebuild stage detached commits (RFC 0067 step 4) #733 did for theirs; step 5 removes them together.Tests
detached_commit_matrix.rsgainsWriter::Merge(a branch holding the row under test, merged into main; the same windows, faults and recovery actors; a race with a main insert makes the merge lose its CAS).failpoints.rs: twenty-five sidecar-era merge tests retire (phase-B recovery on reopen, pointer-slot replay, sidecar delete failure, rollback and restore, armed-prefix rollbacks, first-touch ref recovery, net-zero confirmation, the v1-sidecar classifier synthesis). New: every chunk window and the table and pre-publish windows leave no residue and the retry lands (assert_partial_merge_leaves_no_residueover the adopt and rewrite paths, plus the two multi-chunk fixtures); an interrupted promotion leaves a pending chain of two that the next write promotes link by link; a target advance after the detached effects loses the merge's CAS; a foreign linear commit after the effects blocks promotion, not the merge, and later writes chain behind it; a first-touch fork failure leaves garbage and the retry owns its own fork; pointer adoption carries a pending pin. The pre-arm fences (ABA, sync, source advance, late uncovered drift, pointer adoption) are unchanged. The two issue-694 live-compensation tests and the merge-sidecar body re-read test retire with the compensation path; the follower-attribution test only requires its Optimize producer to advance the table. The foreign-commit test documents that a conflict-free replay over a foreign commit may land as unreferenced history one past it while the pin still names the chain's tip.graph_with_optimize_work+leave_confirmed_optimize_sidecar), the last writer that arms one that survives the next step.write_cost.rs: a merge writes and deletes no control object;merge_cost.rskeeps its delta-scoped open count.branch_merge.post_fork_pre_commitandbranch_merge.post_table_effect;merge_armed_intent_blocks_main_until_reopen.gqtand the two runner tests that needed a corpus case with a genuineRecoveryRequiredretire, because no corpus writer arms a recovery intent any more (the marker stays parsed and refused until the classifier retires); the runner fixtures rename the seam.crates/omnigraph-dst: the crash-window catalog follows the renamed and new merge seams (the mutation and index renames land on engine: mutation and load stage detached commits and publish pins (RFC 0067 step 4a) #731 and engine: ensure_indices and the full-text rebuild stage detached commits (RFC 0067 step 4) #733).writes.md(writer row and the merge's protocol),recovery.md,testing.md, the RFC 0045 example, release note.Review regression tests (17 September 2026)
Seven
failpoints.rscases pin the boundaries the stack review reproduced, five of which failed before the fixes now in #727: the single-link pending-pin diff control, the blocked-chain and pending-merge diffs, cleanup on a blocked pin, the aged detached-manifest reaper, the reader racing a promotion, and a stale handle writing after another handle's promotion (the cause of the intermittent 409s in the server's concurrent-insert test, green eight of eight afterwards). The merge phase topology fix for the bench crate and the maintenance guide's blocked-pin sentence (branch merge and index maintenance stage behind a block) are here too.