Repository navigation
Isolate compact job persistence from settlement locking - #456
Conversation
Retain cluster SHARE before all compact persistence authority checks and join blob collection to the same protocol with an exclusive cluster fence after SETTLEMENT and ORDER, before fresh reference scans. Prove runtime and direct persistence under a held settlement stub, preserve authority/expiry/cancellation assertions at the true row fence, and cover surviving orphan repair races in both collector orders. Require coordinated stop-all upgrades because old collectors cannot fence the new writers. Part of #275; the full refresh performance target remains open.
|
@cursor review |
|
Independent review started against f5dba64: native medium code review, structural/thermo review, independent Fable adversarial review, and separate Codex Sol adversarial review. Cursor review is also requested. All 19 CI jobs are green on this head; review findings and their dispositions will be posted before a merge-ready recommendation. This is a progress record, not a completed review ledger. |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit f5dba64. Configure here.
Final review closeout — f5dba64Merge recommendation: ready for Independent lanes completed against base
The lanes independently traced writer/collector ordering, surviving-orphan repair in both orders, revision/fatal/config fencing, atomic cohorts, cancellation and unknown commit. Their evidence is source analysis; none independently reran PostgreSQL tests. Execution evidence comes from the author's qualification and the green hosted PostgreSQL shards and gate-manifest check, not fabricated reviewer test runs. DispositionsZero required defects remain. Under the approved risk-proportionate review policy, these optional observations do not require another fix round:
No additional production change is requested by this closeout. #275 stays open for delivery-scale and two-frontend qualification; this PR does not establish the one-second full-refresh target or an ARM-specific speedup. |
Compact issued jobs currently wait behind unrelated settlement advisory holders, including the missing-dependency repair path. This change lets compact singleton, batch, repair, and direct prepared persistence complete under a held settlement stub while retaining the cluster authority fence through commit.
The collector joins that protocol with
SETTLEMENT → ORDER → cluster FOR UPDATE → fresh reference scans. Writers retain clusterFOR SHAREbefore revision, writable-state, and configuration checks; direct prepared storage moves those checks behind the fence. This protects surviving orphan blobs during repair and preserves candidate references, retention renewal, exact retries, atomic cohorts, original deadlines, and unknown-commit/cancellation ownership.Upgrade requirement: stop all frontends and collectors, upgrade them together, then restart. An old collector is unsafe with a new unlocked repair writer. Schema and compact format 1 are unchanged; arbitrary rolling compatibility is unsupported.
Part of #275. Fresh publication still performs chain-observation locking, and this PR makes no full-refresh or one-second/2,000-session performance claim. Historical measurement reports remain unchanged.
Validation (disposable PostgreSQL 16, two build jobs / Tokio workers):
cargo clippy --locked --workspace --all-targets -- -D warningspassed.Test commands used
test/prism-native-tests.sh cargo-args --locked -p qbit-prism-serverwith--test-threads=1 --nocapture, selecting:All 436 expected database gates for those selected targets executed. Full workspace formatting, gate-input lint, and diff whitespace checks passed.
No version or changelog changes. Independent review is requested for the lock protocol and supported upgrade boundary.
Need help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.