A re-proposal after an unknown outcome runs the commit check again before
its CAS; the check forgot the kept commit first and looked up every object
again. It now returns at once for exactly the checked commit in its still
open session, the same match the CAS uses to reuse the preparation. The
re-proposal test counts every lookup, not only those inside the CAS.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A detach's cancellation and an unresolved cut's re-proposal now run the
object check before their CAS, as the cut's commit does. The cancellation
adds no chunk, but its new root's segments and root were looked up inside
the HEAD step's fixed limit. The guard requires the check before every HEAD
commit site and lists no exemption; the fixed-limits row names it and the
cancellation's control.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Change rule 7 and table C.L: one row per fixed time limit around work that
grows with the volume, with what runs inside it, what runs outside it under
progress, and its test; three start-path and control rows are STUB until
measured. The unchecked commit is a stated gap kept true by a guard that
classifies every HEAD commit site of the chunk layer and requires the
object check before the cut's commit. Comments at the commit step's lookups
and at the HEAD bound's default mode.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The 2 s HEAD bound wrapped the holder's whole commit call, including the
preparation that grows with the chunk count (manifests, root and segments).
A remote that reports BoundsHeadStep now gets the caller's context plus a
step budget and applies it around each attempt's HEAD read and conditional
write; other remotes keep the whole call bounded. The layout remote reuses
the passed check's prepared request for every attempt of its session, so no
manifest is read and no root rebuilt after the check. The foreign-reference
selection looks at the first two owners only. The provider's wrapper
forwards BoundsHeadStep.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A 1 TiB commit (262,144 chunks) spent 2.47 s inside the 2 s HEAD update
re-deriving the base root and re-scanning the manifests, and its retry did
it again. PlanCommit now computes everything a commit needs from the
request alone (root, segments, base root, the owners of the changed
entries for the foreign-reference check, and the objects to look up)
before the update; the update step only checks the replay, the base, the
owners and writes. CheckCommit plans on the cut's budget and CASHead
reuses that plan and the passed check on every attempt of the same open
session (matched by manifest equality); the check is no longer dropped
before the commit, so a re-proposal after an unknown outcome looks up
nothing.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Main now has a test (from the refused-restore change) that commits a HEAD
through layout.RunCommit; with the cause argument it passes
layout.CauseCommit. Test only.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Review follow-up. The scan now covers package-level initializers, refuses
any writer referenced as a value (a method value or expression), accepts
a forwarded cause only in the four census forwarders and only while it
is never reassigned or redeclared, and refuses a writer call with
another argument count. Negative controls on synthetic source cover each
escape. The store test runs each refusal on a fresh directory, counts
filer write calls, and follows each with a success control under the
right cause.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A HEAD is written by three store calls: the conditional update (only
through runTransition), the exclusive create, and the tombstone. Each now
takes a typed HeadWriteCause, one value per row of the HEAD writer
census, so a writer without a row does not compile. The transitions that
serve one row pass it; RunAbort, RunEndClean and RunCommit, which serve
several, take it from their caller. The layout store refuses a cause
outside the census, a first HEAD not written as create and a tombstone
not written as tombstone. No behaviour changes otherwise.
TestEveryHeadWriteIsACensusRow scans the production source: every HEAD
write names a census constant or forwards its function's cause, and
every row has a writer (both directions); it logs the writers by row.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Review follow-up. The template unit takes the volume id from its
instance name, so a settings file cannot name another volume (a fourth
per-instance directive, kept by the drift test). /status/guests and its
schema say what it is: the counted frontends (NVMe/TCP, iSCSI) only; an
absent frontend is not served or not counted; a vanished host stays
counted until TCP closes; 0 is not proof that nothing uses the volume.
The endpoint test's callbacks use atomics.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
What volume start and volume stop need, before the commands.
/status/guests?volume=<v> reports the guests connected now through each
frontend served: NVMe/TCP hosts (live admin controllers) and iSCSI
initiators (Normal sessions past login; Discovery sessions do not count),
read at request time, and their sum.
deploy/systemd/sw-blockvolume@.service runs one volume per instance
from /etc/sw-block/volumes/<volume>.env with its own state directory;
apart from three per-instance directives it is sw-blockvolume.service,
and a test keeps the two the same.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Remove unnamed roots, segments and chunks through one conditional mark/delete writer. Resume chunk cursors after bounded passes; re-plan metadata first and retain the session initial root set through operator snapshot deletes. Add a local trigger of the existing snapshot schedule for qualification.
The ledger row for the identity rule this change keeps: one name, one
layout identity; no directory but the record's holds a live HEAD. Its
scope: only a refused restore's record (never left the creation phase)
is removed; a served volume's deleted name is never created again. A
guard test proves that name is refused for a plain create, the same
restore request and a new one, with no record and no filer write.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>