Commit Graph
3068 Commits
Author SHA1 Message Date
Ping Qiu da5accc062 Merge pull request #552 from seaweedfs/test/head-readers
test: enumerate every HEAD reader and pin its absent-HEAD behaviour
2026-11-24 10:53:19 -08:00
Ping Qiu 9f98eb0e3b Merge pull request #550 from seaweedfs/test/interrupt-every-step
test: kill volume delete, fork and restore at every step and re-run
2026-11-24 10:46:06 -08:00
pingqiuandClaude Opus 5.5 5d0c9d8cec test: enumerate every HEAD reader and pin its absent-HEAD behaviour
A source scan lists every non-test function in core/ and cmd/ that reads
a volume's HEAD (ReadHead, GetHead, GetHeadRoot, getHeadRoot, headExists,
or a LookupEntry of HEAD) and fails when a reader is added or removed
without classifying it. Each reader names what it does when HEAD is
absent and the probe that pins it; readers that take an absent HEAD for
an empty one are marked GAP, so a change to that behaviour flips their
probes on purpose.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-24 10:43:19 -08:00
pingqiuandClaude Opus 5.5 aec5d41c54 test: kill volume delete, fork and restore at every step and re-run
A trace-driven matrix: each command is run once through a recording
filer to enumerate its filer writes (its step boundaries); then for every
write it is killed before the write reaches the filer and after it
applied with its reply lost, the catalog restarted, and the command
re-run (twice) with the same request id. The end state and the data are
checked: the volume deleted and refused, or the fork's or restore's
image reading back byte for byte. A killed fork's copy intent may outlive
the replay; the test checks it is that request's and that the copy sweep
past the deadline settles it with the image intact. A step added to a
command is covered without editing the test.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-24 10:37:30 -08:00
Ping Qiu c7b8c0f78c Merge pull request #546 from seaweedfs/test/537-slow-precopy-budget-outcome
test(durable): accept bounded slow precopy readiness outcomes
2026-11-24 09:20:14 -08:00
Ping Qiu 7e3c720768 Merge pull request #545 from seaweedfs/test/537-takeover-attach-budget
test(durable): accept bounded takeover readiness refusal
2026-11-24 09:19:36 -08:00
Ping Qiu 06dabf547d Merge pull request #544 from seaweedfs/test/537-cold-precopy-loaded-context
test(durable): quarantine unresolved cold precopy accounting
2026-11-24 09:13:15 -08:00
pingqiu 44498a3ec8 test(durable): pin virtual post-pause expiry to its readiness allowance 2026-11-24 08:39:07 -08:00
pingqiu 7b67e49c3a test(durable): release timely takeover before its own CAS allowance 2026-11-24 08:36:47 -08:00
pingqiu ebf49b4ee9 test(durable): drive virtual attachment through real takeover provider 2026-11-24 08:36:21 -08:00
pingqiu 4601a076e0 test(durable): require deterministic precopy write readiness outcomes 2026-11-24 08:35:24 -08:00
pingqiu a8a2c0b66d test(durable): diagnose missing readiness registration 2026-11-24 08:34:45 -08:00
pingqiu 1c9364e6e0 test(durable): require both attachment budget outcomes on virtual time 2026-11-24 08:33:40 -08:00
pingqiu e7d18a3b6a Merge branch 'test/537-cold-precopy-loaded-context' into test/537-slow-precopy-budget-outcome 2026-11-24 08:17:11 -08:00
pingqiu cd24230842 test(durable): limit precopy quarantine to unresolved cold fixture 2026-11-24 08:16:20 -08:00
pingqiu 5b80c97457 test(durable): cover readiness budget before caller expiry 2026-11-24 08:09:58 -08:00
pingqiu 44873969bd test(durable): distinguish slow precopy caller-budget busy outcome 2026-11-24 08:01:14 -08:00
pingqiu ee67149b11 test: snapshot caller error before reading freeze diagnostics 2026-11-24 08:01:13 -08:00
pingqiu 602e677a8b test: report pre-copy guest error operation and stop timing 2026-11-24 08:01:13 -08:00
pingqiu f13f00d1c8 test(durable): quarantine unresolved precopy accounting and admission 2026-11-24 07:48:14 -08:00
Ping Qiu 22766070d6 Merge pull request #543 from seaweedfs/test/537-csi-loaded-publish-wait
test: allow CSI publish observation after loaded recovery
2026-11-24 07:45:02 -08:00
Ping Qiu 5c24447069 Merge pull request #542 from seaweedfs/test/537-cow-capture-loaded-context
test: allow COW capture context to cover loaded WAL churn
2026-11-24 07:44:34 -08:00
pingqiu 9380992a66 test(durable): avoid assuming delayed CAS prevents HEAD settlement 2026-11-24 07:44:05 -08:00
pingqiu ff5a88edc6 test(durable): honor bounded takeover attachment readiness 2026-11-24 07:41:09 -08:00
pingqiu 709dceca75 test(durable): extend only cold precopy writer context under load 2026-11-24 07:37:38 -08:00
pingqiu 7d7fa5004f test: allow CSI publish observation after loaded recovery 2026-11-24 07:02:41 -08:00
pingqiu 23f2688161 test: allow COW capture context to cover loaded WAL churn 2026-11-24 07:01:55 -08:00
Ping Qiu 324d2edb85 Merge pull request #541 from seaweedfs/test/537-upload-overlap-startup-wait
test: allow upload overlap startup on loaded hosts
2026-11-24 06:33:45 -08:00
Ping Qiu 274ba9c444 Merge pull request #540 from seaweedfs/test/537-csi-private-lock-dir
test: isolate CSI volume subprocess lock directories
2026-11-24 06:33:23 -08:00
Ping Qiu d218e36707 Merge pull request #539 from seaweedfs/test/537-durable-loaded-deadline
test(durable): allow loaded-host setup in plain detach test
2026-11-24 01:18:19 -08:00
pingqiu aba6f601f3 test: allow upload overlap startup on loaded hosts 2026-11-24 00:56:58 -08:00
pingqiu 6411ce74e9 test: give CSI volume subprocesses private lock directories 2026-11-24 00:54:30 -08:00
pingqiu 1378b4b2a9 test(durable): allow loaded-host setup in plain detach test 2026-11-24 00:21:17 -08:00
Ping Qiu aa153f90f5 Merge pull request #536 from seaweedfs/test/hydration-progress-row
test: the status's hydration counters follow first reads
2026-11-23 23:08:42 -08:00
pingqiuandClaude Opus 5.5 3819309942 test: the status's hydration counters follow first reads
A row and a test for the two per-volume counters the status already
reports: the HEAD-named chunks still to hydrate (AbsentChunks) and the
chunks hydrated so far (Hydration.Completed, cumulative). On a restore
target whose HEAD names two chunks they start at 2 and 0; a read of an
un-hydrated chunk moves both by one and a repeat read moves neither, so a
caller can prove a read happened before its chunk was hydrated.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 22:54:21 -08:00
Ping Qiu 1720cd49cc Merge pull request #525 from seaweedfs/test/1.0.1-first-cut-known-zero-red
fix: 1.0.1 a fresh store's chunks that its claimed HEAD does not name start known-zero
2026-11-23 22:43:17 -08:00
Ping Qiu 6bc781c6d7 Merge pull request #534 from seaweedfs/test/sync-covers-wal-guard
test: guard that the flusher sync and the WAL sync are one whole-file sync
2026-11-23 22:42:05 -08:00
pingqiuandClaude Opus 5.5 45134d4581 test: no fetch and no fill reaches a fresh store before its attach commit
A restore target whose HEAD names two chunks, held at the attach commit
boundary: a frontend read of a HEAD-named block is not served, the remote
serves no chunk read, and after the commit both named chunks are still
absent with no fetch started (no fill wrote the extent); the read then
returns HEAD's data. A shortfall in the fresh attach's certification is
logged as a warning.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 22:07:05 -08:00
pingqiuandClaude Opus 5.5 76692a5ef7 test: guard that the flusher sync and the WAL sync are one whole-file sync
A source-level test checks that the store opener binds exactly one data
sync for its file and that both the flusher's extent sync and the WAL
sync use it (a range sync, a second descriptor, or a WAL sync that no
longer calls the shared sync fails it). The checkpoint bound over a
superseded synced record rests on this. The crash test helpers also close
the owned-map file of a crashed store, so the crash tests' directory
cleanup no longer fails where an open file cannot be deleted.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 22:02:21 -08:00
pingqiuandClaude Opus 5.5 2d65269fce fix: report how many chunks a fresh attach certified known-zero
ApplyFreshKnownZero now records the count in Stats.KnownZeroChunks and
logs it; when some sampled chunks stay unknown (a failed map publication
or a raced write) the log says the first cut will scan them, so a lab
run that sees a full first scan has the reason in the status and log.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 21:59:08 -08:00
pingqiuandClaude Opus 5.5 520fb10cf4 durable: gofmt the provider handle struct
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 21:59:08 -08:00
pingqiuandClaude Opus 5.5 9c60d8c247 fix: known-zero needs this start's create; retire the marker before the marking
Two parts of the rule are added. Certification needs the store to have
been created by this process start (an in-memory bit, never persisted):
a fresh marker left by an earlier start, an older binary or another
opener is never trusted, so a first start that dies before its attach
commit pays one scan. And the order is: the attach commit retires the
marker, then the marking is made durable, then the volume serves; a
crash between the first two leaves no marker and every chunk UNKNOWN
(one scan). The user guide states that every explicit implementation
other than walstore-chunk refuses a chunk root.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 21:59:08 -08:00
pingqiuandClaude Opus 5.5 02c153b066 fix: a fresh store's chunks that its claimed HEAD does not name start known-zero
A fresh store (its .chunkfresh marker present at the attach, no BASE) has
never had a write or a fill reach it, so every chunk its claimed HEAD
does not name is zero on both sides. Its attach samples, under the
capture barrier, the token of each such chunk whose owned-map entry is
still the creation value, and clears only their UNKNOWN through the cut's
own map publication, before the attach commit. The first cut of a fresh
volume, hand-over target or restore target then scans only the chunks
written since, not every chunk of the volume. Chunks HEAD names stay
absent and are hydrated from HEAD.

The premise is enforced: every implementation other than walstore-chunk,
explicit as well as auto, refuses a root carrying chunk metadata, so no
plain walstore write can reach a store whose marker says none did.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 21:59:08 -08:00
pingqiuandClaude Opus 5.5 a2441488eb test: red test for a fresh volume's first cut scanning every chunk
A store created empty against a HEAD never claimed, with two chunks
written (one checkpointed out of the WAL), must have two first-cut
candidates and publish both; today all chunks start Unknown and every
chunk of the volume is scanned. Two tests that pass today pin the scope:
a store created against a claimed HEAD, and a restore target, keep every
locally held chunk a candidate.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 21:58:57 -08:00
Ping Qiu 635b9093bb Merge pull request #530 from seaweedfs/test/flusher-unsynced-extent-red
fix: the flusher writes an extent only from a synced WAL record
2026-11-23 21:57:38 -08:00
pingqiuandClaude Opus 5.5 11f817d6d8 test: a checkpoint over a superseded synced record needs the flusher's sync to cover the WAL
b=X and c=Y synced, then b=Z unsynced: the flusher skips b (its newest
entry is unsynced) and its checkpoint passes X's record, which never
reached the extent. Crash after the checkpoint, with the WAL region as of
the last sync that covered it: b reads Z, because the flusher's sync is
the whole-file fsync of the one descriptor. The control models an
extent-only flusher sync and loses X (b reads the bytes from before X),
showing the checkpoint bound rests on that. INV-WAL-FLUSH-SYNC-COVERS-WAL-001
moves from STUB to ACTIVE with this test; INV-WAL-V3-WRITE-AHEAD-001
states the dependency.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 21:26:42 -08:00
pingqiuandClaude Opus 5.5 9ffae70bf9 fix: a flusher cycle with no synced entry is idle; test the pressure path
The flusher keeps only the snapshot's synced entries before its empty
check, so a cycle over unsynced writes alone writes no extent and makes
no fsync (it fsynced an empty batch before). A new test drives a guest
that never flushes: below the WAL pressure threshold nothing reaches the
extent; past it, the flusher's pressure sync makes the writes durable and
the same cycle writes every block's newest bytes and advances the
checkpoint.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 21:26:23 -08:00
pingqiuandClaude Opus 5.5 c921de54e0 fix: the flusher writes an extent only from a synced WAL record
Page writeback has no order across offsets of one file, so an extent
written from a WAL record that is not yet durable could survive a power
loss that loses the record: extent bytes no recovered record or map
entry accounts for, under a chunk certified equal to HEAD. The flusher
now skips dirty entries above the synced (acknowledged) WAL frontier;
they stay dirty until a Sync or the pressure sync makes them durable,
and the checkpoint is computed from the written entries only (it was
already clamped to that frontier). Recover and the install log already
fsync their records before raising the frontier.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 21:26:23 -08:00
pingqiuandClaude Opus 5.5 de0dfd0575 test: red test for a crash keeping an extent write whose WAL record was not synced
The flusher writes a dirty block's extent before its WAL record is synced
(below the WAL pressure threshold it does not sync first). The test runs
the real flusher, cuts the power at its fsync (the extent page it wrote
kept, the unsynced WAL record lost, no checkpoint), recovers and
re-attaches: the block reads the lost write's bytes locally while HEAD
holds the chunk without them, and the chunk is not a cut candidate, so
nothing reconciles local and published. Fails on main.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 21:26:04 -08:00
Ping Qiu c8bcbc7c21 Merge pull request #532 from seaweedfs/docs/template-source-retirement
docs: qualify template source retirement with a dedicated holder
2026-11-23 20:37:12 -08:00