Finalization invariants and fail-closed startup¶
A finalized control plane checks its own invariants before it serves, and refuses to start when one fails. Startup is a hard stop rather than a probe that reports unhealthy while accepting requests.
The check runs before the first request¶
The API server asserts its startup invariants during startup, before any route is reachable. A control plane that comes up serving is therefore evidence about its configuration, not only about its process.
What is asserted¶
flowchart LR
subgraph SRC["WHAT STARTUP READS"]
direction TB
SEC[("Runtime secret")]
LT[("Identity latch<br/>in the store")]
OB["Observed backend<br/>and profile"]
end
G{{"Startup invariants<br/>before any route"}}
SV["Serve"]
RF["503, naming the condition"]
SEC --> G
LT --> G
OB --> G
G --> SV
G -.-> RF
The assertions draw on three sources, and the table below names the condition each one checks. Any failed condition takes the dashed exit, and no route is reachable until every one passes.
Each failure answers 503 with a message naming what was missing or what
drifted:
| Condition | Message |
|---|---|
| No runtime shared secret | finalized control-plane runtime requires auth.runtime_shared_secret |
| No active latch | finalized control-plane runtime requires active immutable cp identity latch |
| Unrecognised latched backend | finalized control-plane runtime requires cp identity latch backend parity metadata |
| Unrecognised latched profile | finalized control-plane runtime requires cp identity latch store profile parity metadata |
| Backend drift | finalized control-plane runtime backend drift detected; latched=<x> observed=<y> |
The drift message carries both values, so the answer to what went wrong is in the message rather than requiring two lookups.
Parity is checked both ways¶
The latch's values are checked for validity and then compared against what the
runtime actually has. A latch naming postgres while the runtime is running on
sqlite is drift, and it is refused with both values named.
Checking validity separately from parity keeps the two failures distinguishable: a latch that was never set correctly is a different problem from a runtime that was pointed at the wrong store.
Startup and readiness are separate probes¶
Both exist and both validate their own probe name before running. Startup is the hard gate; readiness is the continuing answer. Keeping them apart means a control plane that started correctly and later became unready is distinguishable from one that should never have started.
Why fail-closed rather than degrade¶
A control plane serving under an invariant it does not satisfy would write records whose provenance cannot be trusted afterwards. Refusing to serve keeps the recorded state clean at the cost of availability, which is the trade this system makes consistently.
The same posture appears at every boundary: an assignment that does not verify is rejected before a node acts on it, and a run-plan whose signatures do not verify is refused by the kernel. See Control plane as source of truth.
Post-finalization changes¶
Changing a latched value after finalization is denied by default and reachable only through an explicitly audited break-glass path. See Control-plane identity latch.