Files
seaweedfs/sw-block
pingqiu 058305225b sw-block/design: mini-plan §11 C1-C3 hardening sequence
P2d ratified + implemented in seaweed_block (cb8ff1c). Architect
review against §6.8 / consensus v3.8 nine MUSTs identified three
correctness gaps to close, sequenced as C1..C3:

  G-WRITE-RACE   — Sender.writeFrame vs EmitFunc.conn.Write on
                   same dual-lane conn (no shared mutex).
  G-RECORDSHIPPED — WalShipper-routed emits never advance
                   coord.shipCursor.
  G-TIMER        — no self-driving periodic emit-from-cursor;
                   primary-idle starvation possible. NotifyAppend
                   ignores debt (cursor < head) and emits new tail
                   directly — violates send(incoming, debt).
  G-PARALLEL     — Sender.Run runs streamBase fully before
                   sink.DrainBacklog. P6 / G3 requires overlap.

C1 — shared writeMu + post-emit RecordShipped hook (duck-typed
     sink sub-interfaces WriteMu / SetPostEmitHook).
C2 — WalShipper internal timer + NotifyAppend debt-aware dispatch
     using cursor < head (NOT lsn > cursor + 1; that edge-case
     fails at dense single-LSN debt). data arg canonical only on
     no-debt path; debt path drain reads substrate.
C3 — Sender.Run errgroup BASE ∥ WAL parallel; both write through
     shared writeMu (mutex-bounded interleaving, not zero-blocking).

§11.3 records the §6.8 nine-MUST compliance receipt expected
post-C3.

Companion implementation lands on
seaweed_block g7-redo/wal-shipper-impl as three commits.
2026-04-30 02:33:04 -07:00
..

sw-block

Private WAL V2 and standalone block-service workspace.

Purpose:

  • keep WAL V2 design/prototype work isolated from WAL V1 production code in weed/storage/blockvol
  • allow private design notes and experiments to evolve without polluting V1 delivery paths
  • keep the future standalone sw-block product structure clean enough to split into a separate repo later if needed

Suggested layout:

  • design/: shared V2 design docs
  • prototype/: code prototypes and experiments
  • .private/: private notes, phase development, roadmap, and non-public working material

Repository direction:

  • current state: sw-block/ is an isolated workspace inside seaweedfs
  • likely future state: sw-block becomes a standalone sibling repo/product
  • design and prototype structure should therefore stay product-oriented and not depend on SeaweedFS-specific paths