$ fssg build --deterministic --validate |

How to Rehearse Rollback Before an IOSM Cycle

IOSM

A rollback plan is not evidence that rollback works. It is only a claim about a future recovery.

I want IOSM cycles to treat that claim the same way they treat a performance hypothesis or an invariant: make it explicit, test it against a known state, and preserve the result as an artifact. Before a risky change begins, the cycle should answer a practical question: can this system return to its declared checkpoint, and how will we know that it actually did?

That requires more than naming a Git commit or writing “revert if needed” in a task description. It requires a rollback rehearsal.

The missing artifact is a rehearsal manifest

IOSM already gives a change a baseline, hypotheses, phase gates, and a cycle report. IOSM CLI also exposes checkpoints and rollback controls. The gap is the evidence between “a checkpoint exists” and “recovery is proven for this change boundary.”

I model that evidence as a small manifest created before execution:

rehearsal_id: rr-2026-07-29-auth-01
cycle_id: cycle-auth-hardening
scope:
  repository: auth-service
  protected_paths:
    - migrations/
    - config/production.yaml
checkpoint:
  kind: git-revision
  identity: 8d7c1f2
restore:
  command: ./scripts/restore-worktree.sh 8d7c1f2
  destructive: true
probes:
  - id: worktree-clean
    command: git diff --exit-code 8d7c1f2 -- .
  - id: schema-compatible
    command: ./scripts/check-schema.sh
  - id: smoke-auth
    command: npm run test:smoke -- auth
result_policy:
  pass: all-required-probes-pass
  unknown: any-required-probe-missing

The artifact binds five things that are often left separate: the protected scope, checkpoint identity, restore operation, post-restore probes, and decision policy. That binding matters. A checkpoint without a scope can omit external state. A restore command without probes can complete successfully while leaving the service unusable. A green smoke test without checkpoint identity cannot prove which state was recovered.

This is the same reason I separate a phase handoff from a checkpoint. A checkpoint names recoverable state. A handoff transfers authority and context. A rollback rehearsal tests a third property: whether the declared recovery path returns the protected system to an acceptable state.

Rehearse the path, not the disaster

A rehearsal should not create a production incident in order to prove that incidents are recoverable. It runs in an isolated worktree, disposable environment, staging namespace, temporary database, or another boundary where destructive restoration is safe.

The sequence is deliberately boring:

  1. Materialize the declared checkpoint in an isolated target.
  2. Apply a representative bounded mutation.
  3. Execute the exact restore procedure.
  4. Run every required post-restore probe.
  5. Record outputs, tool versions, duration if measured, and the resulting state identity.
  6. Attach the receipt to the cycle before the risky phase is admitted.

The representative mutation must touch the same state classes as the planned change. A source-only mutation cannot validate recovery for a database migration. Restoring a repository does not restore queues, object storage, generated credentials, remote feature flags, or irreversible messages. The manifest must therefore list every state domain it protects and every domain it explicitly does not.

This is a boundary condition, not a footnote. Git documents how to restore tracked content and references, but a Git operation says nothing about external state. Kubernetes can roll a workload back to a previous revision, but its own documentation warns that rollback concerns the rollout history of the workload; it is not a universal transaction across databases and external effects. The recovery claim must be no broader than the mechanism being rehearsed.

The receipt needs identities on both sides

A successful rehearsal should produce a receipt rather than another prose note:

{
  "rehearsal_id": "rr-2026-07-29-auth-01",
  "manifest_hash": "sha256:…",
  "started_from": "8d7c1f2",
  "mutation_id": "fixture:auth-schema-v4",
  "restored_to": "8d7c1f2",
  "probe_results": {
    "worktree-clean": "pass",
    "schema-compatible": "pass",
    "smoke-auth": "pass"
  },
  "uncovered_state": ["production secrets", "external identity provider"],
  "outcome": "pass"
}

started_from and restored_to are not redundant. One identifies the intended origin; the other records the state actually observed after recovery. For file content that may be normalized or generated, the receipt can include a canonical tree hash rather than relying only on a branch name. For databases, the identity may be a migration version plus a verified snapshot identifier. The identity must fit the state domain.

The receipt also preserves uncovered_state. I do not want a partial rehearsal to silently become a universal guarantee. A PASS means that every required probe passed inside the declared scope. UNKNOWN means that a required probe did not run or a state identity could not be established. FAIL means the restore or a required probe failed. These states should not collapse into one Boolean.

That distinction fits the IOSM rule that missing evidence is not zero. Absence is not a favorable result. It removes authority from the decision.

Admission depends on freshness and change shape

A rehearsal receipt should expire when the recovery path changes, not merely after an arbitrary number of days. I would invalidate it when any of these identities changes:

  • the restore script or infrastructure module;
  • the checkpoint mechanism;
  • a required verification probe;
  • the set of protected state domains;
  • the deployment topology;
  • the mutation class of the planned cycle.

A documentation edit and a cross-service schema migration should not inherit the same recovery proof. The receipt belongs to a change shape, not to the repository forever.

This complements the IOSM invariant catalog. Invariants define what must remain true. The rehearsal manifest defines how those truths will be checked after restoration. It also complements decision invalidation: when the restore procedure or protected topology changes, the old admission decision must return to review.

The admission gate can stay simple:

ALLOW risky phase
  only if receipt.outcome == PASS
  and receipt.manifest_hash == current_manifest_hash
  and planned_change.state_domains ⊆ receipt.protected_state
otherwise REVIEW or BLOCK

The subset check is the important part. It prevents recovery evidence for one state domain from laundering permission for another.

What this mechanism does not prove

A rehearsal does not prove that every failure is recoverable. It does not reproduce arbitrary concurrency, corrupted backups, unavailable control planes, or irreversible third-party effects. It does not establish a recovery-time objective unless time is measured under a documented environment. It does not turn destructive migrations into reversible ones.

What it does prove is narrower and useful: for a named change shape, checkpoint, restore procedure, environment, and set of probes, the recovery path produced an acceptable observed state. That is enough to improve an engineering decision without pretending to guarantee the world.

I do not want rollback to remain the paragraph everyone writes and nobody executes. In IOSM, it should become a precondition with an addressable manifest, a reproducible rehearsal, and a receipt that can lose validity. A cycle earns permission to change the system only after recovery stops being an intention and becomes tested evidence.

Sources

FACET AI CLI Terminal
facet@ai:~$