Repository navigation
fix(storage): preserve idle reclaim and LCM retry backoff - #4851
ScriptedAlchemy wants to merge 16 commits into
Conversation
Refs #4481 Rebase the accepted 13-file issue-specific patch intact onto current master without rewriting any existing owner branch. Persist retry and terminal settlement across dirty LCM invalidation, bound store page reclamation, and preserve fatal writer/authority failures while deferring optional SQLite BUSY, LOCKED, or FULL compaction. This clean successor replaces the blocked PR #4808 branch, whose last commit header exceeded the enforced 72-character limit. Carry the exact same 13 file blobs and preserve unrelated master changes.
|
Refs #4481. Propagate an actual SQLite rollback failure instead of masking it with an authority denial; preserve the authority result on success. Exercise a real SQLite authorization refusal during rollback and verify cleanup preserves live rows.
Source and behavioral regression — Refs #4481Published Independent review of the latest diff found that a revoked write authority during optional SQLite vacuum hid a real The new Exact-head Bazel workflow is queued; not yet a passing test claim. No local Bazel is installed; Cargo was not invoked. Leave review/merge holds until CI and end-to-end native macOS daemon measurements pass. This is a partial repair, not |
Exact-head CI repair — Refs #4481The previous PR #4851 Clippy job failed on a real source/test compile error, not a transient infrastructure issue: Root cause: the new Published New exact-head Bazel CI is pending; do not claim the regression passes until that head is green. Previously completed #4810 exact-head CI is green, but that is a separate branch and does not establish #4851 or #4481's daemon acceptance. HOLD MERGE pending exact-head verification, independent review and end-to-end native macOS daemon acceptance. #4481 remains open: idle CPU, retry convergence, highly fragmented recovery and 24-hour store-growth acceptance have not been proven on |
Exact-head Linux Bazel fleet blocker — Refs #4481 (2026-11-09)The current #4851 head
This is an observed exact-head CI blocker, not evidence yet that the 13-file reclaim/backoff patch caused these three failures, nor evidence they are pre-existing flakes. The native macOS end-to-end idle-CPU, retry-convergence, and 24-hour store-growth requirements remain independently unproven. Parent workflow 42692895291 was still running Windows when checked, so the correct next verification is to rerun the failed Linux fleet job only after the parent completes. If the same failures reproduce, inspect their real runtime phase timings / readiness ownership and coordinate with the relevant fixture owners rather than raising timeouts or weakening assertions. Keep the #4851 HOLD MERGE and #4481 open. No Cargo, production changes, peer-branch mutations, draft changes, or CI bypass. |
Refs #4481 Never reuse a SQLite writer connection if optional page reclamation leaves an open transaction. Drop the connection and reject queued work before a later write can accidentally join that transaction. Settle recoverable vacuum errors normally when SQLite is back in autocommit. Exercise a real SQLite rollback refusal plus successful rollback, contention and read-only paths to distinguish fatal and safe outcomes.
Refs #4481 Keep the fail-closed writer fix within the Rust formatting line budget.
Fail-closed SQLite writer repair — Refs #4481 (2026-11-09)Published Confirmed defect: The preceding rollback-error regression deliberately made SQLite refuse Repair: Every actual vacuum outcome now checks whether SQLite returned to autocommit. If not, the production worker marks itself Behavioral checks: Extended the existing real SQLite authorizer rollback-refusal regression to assert that the writer must retire, and the actual contention/read-only and successful-rollback tests to assert the opposite. These exercise SQLite connection state rather than synthetic error-string classification. An independent source/diff review found the retirement restricted to the failed-transaction boundary; the prior error propagation is unchanged. Exact-head Bazel workflow on HOLD MERGE. The unrelated Linux fleet failures on previous head |
Refs #4481 Close buffered writer ingress before retirement, drain already-admitted commands, and reconcile typed fault replies and queue telemetry. Real channel regression covers buffered and parked writes plus late admission.
Source review and targeted repair — Refs #4481Published Root cause: the preceding fatal-vacuum retirement closed the SQLite connection but skipped accepted requests still in its bounded ingress receivers. Those callers observed a dropped reply instead of the typed Behavioral regression: a real MPSC channel holds an unread accepted write while another is already parked in the fair queue. Both receive typed fault replies; queued operations/bytes return to zero, completion counts match admitted work, and a late send is refused. This test is not a source-shape assertion. Exact-head Bazel workflow #42729796684 has started in queued state. No passing result is claimed. Bazel is unavailable in this execution environment; Cargo was not run. Independent native macOS idle-CPU, retry-convergence, fragmented receipt scaling and 24-hour bounded-store acceptance are not proven on master ( |
Use explicit rollback for vacuum execution and commit failures so a failed rollback cannot masquerade as a retryable busy or disk-full condition. Preserve automatic SQLite rollback on disk-full and retire writers when a transaction cannot be closed. Add real-SQLite contention, refusal, recovery, and data-retention regressions. Refs #4481
Explicit SQLite cleanup on vacuum failure — Refs #4481Published Root cause: optional The writer now explicitly rolls back on both error paths, preserves rollback failures as fatal diagnostics, distinguishes SQLite's automatic rollback on Independent verification: four independent real-SQLite reproduction cases passed on SQLite 3.46.1. These are not Rust/Bazel evidence. Local Bazel and the affected native macOS daemon are unavailable. New exact-head Bazel CI #42737462258 is queued; no passing result is claimed. Hold merge and keep #4481 open until CI and measured native macOS idle CPU, retry convergence, and 24-hour physical-store growth are proven on master. No Cargo was used. |
Apply the four Bazel rustfmt_check_2024 hunks from CI run 42737462258. Retain test logic, admissions, rollback observations and assertions. Refs #4481
An execution-batch fault formerly dropped later selected batches, losing caller replies and leaving queue telemetry inflated. Fail those accepted requests with typed Faulted outcomes before retiring the worker. Refs #4481
Align the existing behavioral regression with rustfmt so the Bazel repository gate can complete and exercise the source fix. Refs #4481
Refs #4481 Faulted actors must not retain SQLite connections until registered senders disconnect. Close ingress and drain accepted work on retirement. Exercise the live writer and verify typed replies and zero queued bytes.
Refs #4481 The vacuum worker kept a named begin-transaction Result live through its failure arm, so inspecting the connection there conflicted with the mutable borrow (E0502). Reduce the begin result to an owned error in a let-else scrutinee, preserving settle-then-report ordering. The fault regression also needs the QueueItem trait in scope and a pinned-rustfmt wrap. No retry, vacuum, authority, or assertion behavior changes. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Scope
Refs #4481 — partial repair. HOLD MERGE until independent review, exact-head Bazel CI and prerequisites are satisfied. Do not close #4481 without master-proven native macOS daemon acceptance.
This is the clean, non-force successor to #4808 after its November 9 repository-gates failure found a 74-character final commit header, over the 72-character enforced limit. The authored-header failure also caused the Feature gates aggregate to fail. Since the owner requires no force pushes or rewritten concurrent branches, this replacement is one properly titled commit on current
master, not a rewrite of the old branch.The replacement carries all 13 exact file blobs from #4808 head
1301327af043, based onmasterd6acbc49f791. A compare of both diffs confirms identical changed-file paths and additions/deletions, with no overlap against the eight commits added to master since #4808's prior base. All old branches and other owners' work are preserved.Production fix and nonvacuous regressions
SQLITE_FULL, while propagating writer shutdown, revoked authority, read-only and other storage failures.Verification and remaining acceptance
master. This PR does not claim the whole issue is fixed.No changes to #4776 or Kev/decision-model drafts; release #4763 stays read-only.