Repository navigation
fix(api): refresh facade authority after compaction - #1234
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Warning Billing warning: we have not been able to collect payment for this subscription for more than 72 hours. Please update the payment method or pay any pending invoices in Billing to avoid service interruption. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Compaction published a new generation while leaving the calling facade's private workspace and reader authorities at the old parent. The next SET failed, and a UUID-only refresh could republish stale data. This change prepares and installs the complete selected workspace, property/ordinal/adjacency authorities, catalog and bindings; active lazy streams retain the old workspace until their readers release it.
The Rust facade operation now requires mutable access, with thin Python/Node/CLI callers updated accordingly. Existing storage entrypoints keep their lifecycle behavior. The facade checks its expected parent, preserves writer/admission guards, and runs normal recovery after an authenticated own post-CURRENT error so an immediate exact retry finds the completed receipt. Current-format partial compaction remains an explicit refusal.
Validation covers CAS and actual adjacency-backed generation-owned publishing at 33/4,097 nodes, two logical routes and sharded construction; same-handle SET/CREATE/DELETE, null/removal semantics, non-reused IDs, lazy snapshots, reopen, exact query, export/full verify/clean import, and mixed exploratory/qualified-route SET/CREATE. Four subprocess cases distinguish crash recovery from same-facade continuation after returned errors before/after CURRENT. The populated UUID-cache/workspace-release test is selected into Windows and macOS CI.
Resource assertions preserve CAS sharing (192 KiB writes/1 MiB reads/eight copies/16 fsyncs) and separately bound existing generation-owned private copying (1 MiB writes/2 MiB reads/64 copies/128 fsyncs). Staged output and later Parquet payload stay within 1 MiB for these fixtures; reported logical compaction state stays within 4 KiB with zero reported spill. Compression is checked after compaction and later mutations. These are fixture component budgets, not universal process-RSS limits. Source-bound CPU, RSS, syscall I/O and sampled inode-allocation evidence is recorded in the storage assessment; the invalid baseline cannot support a complete-lifecycle speed comparison.
Local validation: 736 API unit tests; all 31 public-storage tests; five storage compaction tests; targeted immediate error-retry and mixed-route additions; workspace clippy with warnings denied; formatting, gate registry and
make pre-push-fast. Required exact-head CI and native lanes must pass before merge. Independent review findings were verified and repaired; no outstanding local finding remains.Closes #1231. Part of #1194; canonical publishing-contract gate #1221 remains open. The remaining exploratory edge-property owner case stays on reopened #1224, and same-name ontology promotion remains #1229. No compatibility or migration machinery is introduced.
Need help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.