Goal
Qualify durable pipeline effect identity and safe restart for native OSH. NOT A MASTER PLAN; follow OSH umbrella #158 and existing architectural sequencing.
Verified baseline
native/kernel/core/osh_op.hexplicitly calls current intent records RAM-only, with astruct osh_intentseam andosh_op_recover()that reports open intents asOUTCOME_UNKNOWN, not replayed.native/kernel/core/osh_op.cuses this seam in the QEMU test adapter.- OSH ABI §10 and §13 requires durable intent before write/spawn and outcome after, with conservative unknown results.
Implementation
- Audit the existing native Artifact Store/Cortex and evidence paths for a suitable durable record sink; do not invent a second ledger where an existing verified writer suffices.
- Bind each pipeline/stage effect to request digest, operator/agent principal, capability domain/index/generation, stage identity and input/target hashes as available; separate provisional result, finished result and immutable receipt.
- Journal intent durably before any effect; write/finalize outcome only after observed completion. If durability is unavailable, refuse effectful stages by name, not silently downgrade.
- Recover unfinished effects as
OUTCOME_UNKNOWN; never auto-repeat a possibly executed mutation. Allow explicit operator reconciliation through existing authority. - Fault-inject crash before intent, after intent, after spawn/write, after finish, during cancellation and during receipt writing; verify exact counts and no duplicate effects.
- Keep read-only recovery/inspection available even when OSH itself fails.
Definition of done
- Deterministic host + QEMU tests demonstrate fail-closed journal unavailability and precise recovery categories, with pinned signed Spark judge evidence.
- No claim of exactly-once or undo/reversibility unless separately proven.
- Native image enablement depends on passing this gate; do not count RAM-only test success as durable acceptance.
Dependency: native streams and multi-command task/OSH issues; protocols #43.