Resolve the conflict in the ProviderConfig comments: keep main's new DetachFreezeTimeout field and the corrected ChunkDirtyThreshold comment.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Fold of the #258 review:
- the probe opens the volume once, locks that descriptor first, then
identifies the same open file as v3: a path replaced between two opens
can no longer yield a false unheld, and a locked file is held whatever
it is;
- locking before reading also fixes Windows, where an owner's byte lock
refused the probe's earlier read (it reported unknown, not held);
- the test reaps its holder process on every path; the CLI test closes
its store unconditionally;
- the usage text adds that the probe is momentary and reserves nothing.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ProbeVolumeUnheld takes and releases the exclusive, nonblocking advisory
lock that every v3 owner holds while its store is open; the kernel drops
it when the owner process exits. nil means no process on this host holds
the volume; ErrVolumeHeld means one does; anything else is unknown (a
non-v3 file is refused: its owner would not take the lock).
`sw-block ops volume-unheld --path P` exits 0 only when unheld (1 held,
2 unknown). The proof is per host and for local filesystems only; host
cleanup must also check that the owner process is gone.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The test waits out the real ~45 s horizon; a 60 s budget left ~15 s for
the takeover, cut, detach and delete, which load and -race exceeded.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A holder that exits never detaches or ACKs, so its live authority keeps
a volume delete refused. The existing path recovers it: after the lease
horizon plus skew a forced move grants epoch+1 on another host, which
claims HEAD, serves the last cut and writes past it, then detaches with
a clean ACK, after which the delete is admitted and later renewals and
moves are refused. Real master runtime and providers, in-memory remote.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Fold of the #248 review:
- the v3 seed logs after the capture and lifecycle locks are released,
and names its intervals for what they include (lock wait, store mutex
and validation, data sync incl. sync serialization, checkpoint publish);
- the HEAD claim logs its start before the claim's own HEAD read and its
elapsed time on failure; the observed HEAD is logged as an observation;
- a close during the attach retry backoff ends the wait as closed, not
superseded.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- master slow store: each held Put takes a generation; a renewal is credited
with the generation it read before its call, so a reply computed before
the hold never releases it. slow.release() runs as the first cleanup, so a
held Put cannot block the publisher/extender joins after a failure.
- authority WritersExtendersClose: only grants of calls that started after
the extension write was held count (flag set before the hold blocks).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- core/host/master TestWorkspaceLeaseGuardSurvivesSlowAuthorityStore: each
lease write is held until a renewal succeeded during the hold (slowness by
progress), three held writes must complete, a sampler records any fence;
replaces the 2.5 s sleeps and the 10 s watch. A renewal that waited for the
store would let the guard lapse and fail the test at once.
- TestWorkspaceHeldRenewalBoundary, TestWorkspaceMoveRestoresLazilyAndFencesOldHost:
the test context has no wall-clock bound (3 s / 10 s); each step completes
or the go test timeout reports the hang. The guard's own RPC timeout stays.
- core/authority TestWorkspaceLeaseConcurrentRenewalsWritersExtendersClose:
wait for the held extension write and for renewals under it by progress
(were 5 s / 2 s bounds); joins after release unchanged.
- waitExtenders joins the finite extenders without a 10 s bound.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A deferred chunk attach was silent from the end of local recovery until
it served or failed. Log:
- entering the authority wait, with the projection fields that fail;
- the first attach attempt, once the projection carries authority;
- an attach that found authority gone again;
- the HEAD claim start (observed HEAD gen/epoch/holder/state/remote LSN
and the target epoch/holder) and its end with the duration;
- how the wait ended (attached after N attempts, fenced, closed,
superseded, or assignment unavailable with the fields still missing);
- the v3 seed's lock wait, data fsync and checkpoint publish durations.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The flag help and the ChunkDirtyThreshold comment still described the
cut as it was before copy-before-write: "bound on one cut's barrier
copy" and "0 = unbounded".
Since the chunk copy moved out of the barrier, the value is the number
of candidate chunks above which a cut pre-copies (stages) chunks before
its barrier, in rounds of that size, and 0 disables pre-copy
(chunk_layer.go, stage: a bound <= 0 returns without staging).
Text only. No behaviour change.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
The no-host-validity refusal in RenewWorkspaceLease formatted its error
from lv.d.horizon after releasing leaseMu, while the extender
(refreshLeaseViewLocked) rewrites the view under leaseMu: a data race.
The horizon is now read before the unlock.
Test: TestWorkspaceLeaseRefusalReadsTheViewUnderTheLock drives the
refusal while the view is republished concurrently; under -race it fails
on main (workspace_lease_view.go:174) and passes here.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Review fold (P2 cleanup, test only): an idempotent release and bounded
joins of the started workers are registered with t.Cleanup before any
worker starts, so a Fatal while the replay is parked cannot leave it
running past teardown. A join timeout is reported as an error.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Review fold (P2, tests only): the positive RF1@3 steps now write and read
back through a backend at the epoch-3 identity (exact n, nil error); the
stale-RF2 test requires a successful write. New two-worker test: the replay
worker's RF1@2 parks in the peer-set update, the stream worker's RF2@3 is
refused meanwhile, then the replay resumes; bounded by timeouts.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>