store: load-batch parent skeleton; drop LiveUnion - #275
Merged
Conversation
Contributor
Author
|
Retrigger Actions: pull_request workflow did not schedule after open. |
4 tasks
A later height in the lookup wave that spends an earlier create must not probe tx.head. Load binds those via same-batch or in-flight. Co-authored-by: Cursor <cursoragent@cursor.com>
Lookup TipOnly-fills BatchParentIds (fk + body/spent ranges) onto each LoadBatch. Load binds same-batch → in-flight → skeleton → Corrupt with no leftover tx.head probe on IBD. PublishedIds / LiveUnion / layer_chain are gone; hashers live in id_map. Co-authored-by: Cursor <cursoragent@cursor.com>
Owner docs and ibd: perf drop union=/keep=. Bind order is same-batch → in-flight → skeleton → Corrupt. In-flight prune stays the lookup-wave drain+fence snapshot on the last load batch (#277). Co-authored-by: Cursor <cursoragent@cursor.com>
rearden-grok
Bot
force-pushed
the
store/batch-parent-ids
branch
from
August 26, 2026 18:52
d531d81 to
61c2e7a
Compare
6 tasks
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.
Summary
PR2 of the batch-parent-skeleton plan. Rebased on master after #277 (lookup-wave drain+fence snapshot on the last load batch).
BatchParentIds(create_fk + body/spent ranges + per-chunk need-vouts) onto eachLoadBatch.tx.head.LiveUnion/PublishedIds/layer_chainare deleted. plan=None / S0 still leftover TipOnly.wave=nestsspent=(tx_spent_range_batchfor TipOnly hits).union=/keep=are gone fromibd: perf/ibd: sizes.drain_and_fence_hibefore TipOnly and passes it on the last load batch; load drops tagged layers withmax_heightbelow that after the in-flight read. Equality keeps. Notuntil = lookup_started_hi.Live pause (do not merge until operator IBD)
leftover_n=0/pin_txid%=100on IBD load (no Class A identity hits on the load thread).union=gone fromibd: sizes.parent create_fk unresolved.iflight=drops when a later wave's pre-TipOnly drain+fence snapshot is below the pack height and that wave's last load batch has finished its in-flight read.#277 already zeroed leftover occupancy on a 473k restart. This PR is still the leftover=0 bind path (skeleton, no load TipOnly). Dropping in-flight on the #277 snapshot is required so pin can use skeleton ranges after the layer is gone.
Test plan
cargo test -p rbitcoin-query --lib -- stamp skeleton id_map archive_plan in_flightcargo test -p rbitcoin-consensus --lib -- bq_resolve same_wave skeleton parent_pincargo test -p rbitcoin-net --lib -- chunk_parent perf_log confirmMade with Cursor