All 43 actions pass on m01/m02 hardware. Auto-failover PASS. dd_write: 30s → 123ms. Post-failover write: 33,621 IOPS. 1. WAL retention: remove keepup retention floor (MinShippedLSN). WAL cannot be pinned during sustained async writes — any pin strategy either fills WAL (blocking writes) or over-recycles (breaking catch-up). Flusher recycles freely. Future LBA map will provide catch-up without WAL retention. MinShippedLSN on ShipperGroup retained as diagnostic surface. 2. Registry stale-cleanup race: add RegisteredAt grace period. Race: master registers volume → next VS heartbeat arrives before VS discovers the volume → stale cleanup deletes the entry → failover finds 0 entries. Fix: skip stale cleanup for entries registered within 30s (> 2 heartbeat intervals). 2 new tests: grace protects new entry, old entry still cleaned. 3. Shutdown heartbeat: VS disconnect heartbeat no longer claims block inventory authority. Previously, the shutdown beat's empty inventory triggered stale cleanup, deleting the entry before failover could use it. Scenario fix: recovery-baseline-failover.yaml now kills the correct node (discovered primary, not hardcoded), connects to the correct new primary for post-failover verification. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
14 KiB
V2 Capability Map
Date: 2026-04-05 Status: active Purpose: define the V2 capability expansion map that drives feature closure, test closure, and the transition from bounded scenario debugging to systematic product validation
Why This Document Exists
If V2 is a real system line, it needs more than:
- accepted protocol truths
- passing point fixes
- a few successful scenarios
It also needs one explicit map that answers:
- what product capabilities exist in the V2 line
- in what order those capabilities should close
- what "done" means for each capability
- which tests prove the capability
- which proofs are V2-owned versus runtime-specific
This document is that map.
It complements:
v2-protocol-truths.mdfor stable semantic rulesv2-product-completion-overview.mdfor product-level completion statusv2-phase-development-plan.mdfor active execution sequencingv2_scenarios.mdfor scenario backlog and historical failure sources
How To Use This Map
For any new feature, bug fix, or test expansion, ask:
- which capability tier does this belong to
- which closure claim does it strengthen
- which proof tier should carry it
- whether it is V2-owned truth or current-runtime integration
This prevents three common failures:
- growing V2 by random scenario accumulation
- confusing
weedintegration success with V2 semantic completion - re-testing everything from zero when the runtime boundary changes later
Core Method
The map uses three linked ideas:
1. Capability expansion
V2 should expand from:
- single-volume correctness
- bounded RF=2 replication
- failover and rejoin
- multi-replica behavior
- lifecycle operations
- control-plane and operations closure
- CSI and product-surface closure
2. Completion definition
A capability is not "done" because code exists.
It is only closed when all of these are true:
- semantic rule is explicit
- runtime path exists
- observability exists
- focused tests prove the rule
- one product-level scenario proves the real path
3. Proof layering
Each capability should be proven across four proof tiers:
Core semantic- pure V2 truth
- fastest feedback
- should remain reusable if runtime changes
Seam / adapter- queue, heartbeat, registry, proto, assignment, bridge ownership
- catches most integrated bugs cheaply
Integrated runtime- real
weedpath today - smaller number of high-value scenarios
- real
Soak / benchmark / adversarial- slow, broad, or disturbance-heavy validation
- not the daily development loop
Capability Tiers
Tier 0: Semantic Foundation
Goal:
- make V2 the source of truth for replication semantics
Main closure claims:
- epoch and lineage are authoritative
- committed truth is explicit
- catch-up versus rebuild boundary is explicit
- stale authority fails closed
- replica identity is stable across endpoint change
Done means:
- truths are explicit in
v2-protocol-truths.md - engine events and commands preserve those truths
- core tests cover replay, stale events, fencing, and recovery choice
Primary proof tiers:
- core semantic
- seam only where identity/transport adaptation matters
Typical tests:
- event -> projection -> command tests
- recovery-choice tests
- stale session / stale epoch rejection
- stable
ReplicaIDversus mutable endpoint tests
Tier 1: Single-Volume Base Capability
Goal:
- prove one volume is correct before adding replication
Capabilities:
- create/delete
- single-node read/write
- restart durability
- publication correctness
- bounded observability
Done means:
- RF=1 write/read survives restart
- publication reflects the true serving node
- explicit health/publication state is observable
Primary proof tiers:
- core semantic for boundaries
- integrated runtime for real read/write/restart
Typical scenarios:
- create -> write -> restart -> read
- publication remains coherent after restart
Tier 2: RF=2 Replication Base
Goal:
- close the smallest useful HA replication unit
Capabilities:
- primary/replica assignment
- receiver readiness
- shipper configuration
- barrier semantics
- explicit
publish_healthy - explicit
degraded - explicit
needs_rebuild
Done means:
- replica membership reaches the primary truthfully
sync_allcannot succeed vacuously with zero shippers- publication health depends on real closure, not optimistic state
- RF=2 replicated write/read works on the integrated path
Primary proof tiers:
- core semantic
- seam
- one integrated replicated IO scenario
Typical tests:
- assignment-delivered membership tests
RoleApplied,ReceiverReady,ShipperConfiguredclosure tests- barrier strictness tests
- replicated checksum scenarios
Tier 3: RF=2 Recovery And Failover
Goal:
- turn RF=2 replication into a fault-tolerant runtime path
Capabilities:
- manual promote
- auto failover
- old primary fencing
- old primary rejoin
- catch-up-first reconnect
- rebuild fallback
- data continuity after failover
Done means:
- promotion bumps epoch and fences stale authority
- promoted primary regains replica membership after rejoin
- reconnect chooses catch-up or rebuild explicitly
- failover preserves committed data
- one data-verified integrated scenario exists for each supported failover path
Primary proof tiers:
- seam
- integrated runtime
- soak/adversarial for disturbance variants
Current note:
- manual promote on the integrated
weedpath has now closed with data continuity verification - this tier remains broader than one passing scenario and still requires systematic matrix expansion
Typical scenarios:
- kill primary -> promote replica -> restart old primary -> data verified
- lease-expiry auto failover
- rejoin with address change
- rebuild fallback when catch-up path is unavailable
Tier 4: Multi-Replica Runtime (RF>=3)
Goal:
- extend the model from one replica to a replica set
Capabilities:
- multi-replica membership
- multi-shipper convergence
- strict
sync_all sync_quorum- partial failure tolerance
- replacement and rebuild target choice
Done means:
- primary ownership and closure remain replica-scoped, not scalar-only
- quorum/all durability rules hold under mixed replica states
- failover and rejoin do not collapse back to RF=2-only assumptions
Primary proof tiers:
- core semantic
- seam
- targeted integrated RF=3 scenarios
Typical tests:
- multi-replica assignment closure
- quorum durability tests
- partial-failure promotion eligibility tests
- RF=3 disturbance scenarios
Tier 5: Lifecycle Capability
Goal:
- prove that product operations remain correct under replication and recovery
Capabilities:
- expand
- truncate
- snapshot
- snapshot export/import
- clone/restore style flows where supported
Done means:
- lifecycle operations preserve V2 recovery truth
- lifecycle metadata does not bypass fencing or recovery boundaries
- lifecycle operations continue to hold under restart/failover
Primary proof tiers:
- core semantic for boundary rules
- seam where command ownership matters
- integrated scenarios for user-visible lifecycle behavior
Typical scenarios:
- snapshot then failover
- expand under replicated volume
- truncate under degraded or catch-up conditions
Tier 6: Control Plane And Operations
Goal:
- make the system diagnosable and operationally trustworthy
Capabilities:
- heartbeat convergence
- assignment queue correctness
- registry truth coherence
- publication truth coherence
- debug surfaces
- metrics and operator diagnosis
- restart and disturbance policy clarity
Done means:
- the control plane reports the same truth the runtime acts on
- major failure classes are diagnosable from bounded logs/debug state
- restart/rejoin behavior is policy-shaped, not accidental
Primary proof tiers:
- seam
- integrated runtime
- soak for repeated disturbance
Typical tests:
- registry/publication coherence tests
- assignment queue confirm/refresh tests
- reconnect/restart diagnosis tests
- bounded failover observability tests
Tier 7: Product Surfaces (CSI, iSCSI, NVMe)
Goal:
- project V2 storage truth through real product interfaces
Capabilities:
- volume create/publish through
CSI - node stage/node publish
- failover-visible remount or reconnect behavior
- expansion through product surface
- snapshot through product surface
- front-end publication coherence
Done means:
- product surfaces do not hide or weaken V2 truth
- frontend publication follows actual authority after failover
- product workflows survive supported restart/failover envelopes
Primary proof tiers:
- seam
- integrated runtime
- slower end-to-end scenario pack
Typical scenarios:
- CSI create/publish/write/failover/read
- CSI expand under replicated volume
- snapshot + restore + failover
Tier 8: Launch Envelope
Goal:
- convert bounded capability proof into a bounded support statement
Capabilities:
- supported topology matrix
- supported disturbance matrix
- known unsupported branches
- pilot stop conditions
- rollout review evidence
Done means:
- supported claims are explicit
- unsupported areas are explicit
- pilot and rollout review use the same capability map and proof layers
Primary proof tiers:
- integrated runtime
- soak / perf / operational review
Capability Map Summary
| Tier | Scope | What closes here | Main proof emphasis |
|---|---|---|---|
| 0 | Semantic foundation | truth rules and fail-closed boundaries | core semantic |
| 1 | Single-volume base | RF=1 correctness and restart durability | core + integrated |
| 2 | RF=2 replication | receiver/shipper/barrier/publication closure | core + seam + one integrated path |
| 3 | RF=2 recovery/failover | promote, rejoin, catch-up, rebuild, data continuity | seam + integrated |
| 4 | RF>=3 runtime | multi-replica membership and durability semantics | core + seam + targeted integrated |
| 5 | Lifecycle | snapshot/expand/truncate under replication truth | mixed by feature |
| 6 | Control/ops | registry/heartbeat/publication/diagnosis closure | seam + integrated |
| 7 | Product surfaces | CSI and frontend projection of V2 truth | integrated |
| 8 | Launch envelope | bounded support and rollout claims | integrated + soak |
Matrix Linkage
Use the three active documents in a fixed order:
- protocol docs define the rule
- this capability map defines which product tier owns the rule
v2-validation-matrix.mddefines what must be proven for closurev2-integration-matrix.mddefines which real scenarios exercise the path
The goal is to make the chain explicit:
protocol -> capability tier -> validation rows -> integration rows
| Tier | Primary protocol refs | Validation rows | Integration rows | Practical meaning |
|---|---|---|---|---|
| 0 | v2-protocol-truths.md, v2-sync-recovery-protocol.md |
V4, V5, V14 |
feeds I-V1 through I-V6 |
pure semantic truth and fail-closed rules |
| 1 | v2-protocol-truths.md |
V1 |
I-V1 |
single-volume and bootstrap correctness |
| 2 | v2-sync-recovery-protocol.md |
V1, V2, V4 |
I-V1, I-V2 |
RF=2 replication base and barrier/publication closure |
| 3 | v2-sync-recovery-protocol.md, v2-rebuild-mvp-session-protocol.md |
R1-R12, V3, V6, V7, V8, V11 |
I-R1-I-R8, I-V3, I-V4, I-V5 |
recovery, rebuild, failover, and rejoin |
| 4 | v2-sync-recovery-protocol.md |
V9, V10 |
future RF>=3 integrated rows |
aggregate multi-replica projection and durability semantics |
| 5 | v2-rebuild-mvp-session-protocol.md, snapshot/restore execution docs |
S1-S10 |
I-S1-I-S4 |
snapshot, restore, and lifecycle operations |
| 6 | v2-automata-ownership-map.md, v2-protocol-claim-and-evidence.md |
V8, V12, V13 |
I-V4, I-V6 |
control-plane truth, observability, and operator surfaces |
| 7 | product-surface and rollout docs | V1, V2, V12, V13 |
runner scenarios and product e2e packs | CSI/frontend projection of V2 truth |
| 8 | rollout/support docs | stage-gate summaries in validation matrix | chaos/perf rows I-C1-I-C4, I-P1-I-P3 |
bounded launch envelope and operational confidence |
Test Expansion Strategy From This Map
This map should drive testing in a faster order than "one expensive scenario at a time."
Fast lane
Run on most code changes:
- core semantic tests for the touched rule
- seam tests for ingress/egress/control delivery
- one focused scenario only if the change crosses a real product seam
Medium lane
Run on milestone closure for a tier:
- representative integrated scenarios for that tier
- checksum or historical-read validation where data continuity matters
Slow lane
Run on nightly or bounded review:
- disturbance matrix
- soak
- benchmark
- larger product-surface packs
What Must Stay Runtime-Agnostic
To avoid re-testing everything from zero when weed ownership shrinks later,
these proof categories must stay V2-owned:
- assignment semantics
- role/epoch/fencing semantics
- recovery-choice semantics
- publication closure semantics
- data continuity contracts
The current weed path remains valuable as:
- the present integrated runtime
- one proof backend for product-level behavior
It must not become the only place where V2 truth is tested.
Immediate Next Use
This map should be used to produce:
- one capability-to-test taxonomy
- one current coverage matrix marking which tiers are:
strongboundedpartialnot yet closed
- one reduced high-value integrated scenario pack aligned to tiers rather than ad hoc bug history
Current Practical Reading
For near-term work, read in this order:
v2-protocol-truths.mdv2-capability-map.mdv2-product-completion-overview.mdv2-phase-development-plan.mdv2_scenarios.md