Skip to content

Control plane as source of truth

Source of truth is an ordering guarantee before it is a storage claim: a decision is recorded before anything acts on it, and what acted carries the identifiers of the record it acted on. This page is the mechanism that holds that ordering, and what to read when a deployment is not doing what you expect.

For what the control plane decides, see Control plane as source of truth in Concepts.

The records

flowchart LR
  C["You, through the API"]
  subgraph CP["CONTROL PLANE"]
    direction TB
    REC[("Versioned records<br/>with governance revision")]
    LED[("Assignment ledger<br/>immutable snapshots")]
    REP[("Reports<br/>fence, observed generation")]
    REC --> LED
  end
  subgraph YI["YOUR INFRASTRUCTURE"]
    direction TB
    N["xratud"]
  end
  C -->|"admitted request"| REC
  N -->|"pulls"| LED
  N -->|"posts"| REP

Everything authoritative is inside the control plane box, and the node holds none of it. Both of the node's edges start at the node: it pulls from the ledger and posts to reports, so the control plane never opens a connection into your infrastructure.

The order every change follows

flowchart TB
  A["Request admitted<br/>scope resolved, RBAC evaluated"]
  B["Record written<br/>versioned, with a governance revision"]
  C["Assignment authored<br/>immutable snapshot on the ledger"]
  D["Node acts<br/>after verifying the snapshot"]
  E["Report recorded<br/>carrying fence and observed generation"]
  A --> B --> C --> D --> E

Each arrow is a boundary a value must survive. A node acts on step C and reports against step E, so a run is explained by reading the assignment it was given and the report it returned, rather than by inspecting the node.

Recorded state is versioned, and a version is final

A published version is not edited. An attempt to write over one is refused by name rather than merged:

flow_definition version already exists and is immutable; create a new version instead

The same rule holds for policy bundles, package releases and project releases. The consequence for diagnosis is that a version identifier is sufficient evidence: if two runs name the same version, they ran the same definition, and no reconciliation of content is needed to establish it.

Tenancy and governance records carry a governance revision that advances by one on every change, so a policy decision can be attributed to the revision in force when it was made.

The identity latch

A finalized control plane holds an identity latch, and a restart is checked against it before the runtime serves. It records:

cp_instance_uuid       this control plane's identity
cp_identity_revision   the revision of that identity
locked_db_backend      sqlite or postgres
locked_store_profile   lightweight, standard or durable

Startup is fail-closed rather than probe-only. A runtime whose backend or store profile does not match the latched values does not serve, and runtime credentials are bound to the latch claims and rejected on identity drift. The latch answers with one of three reason codes:

Reason code Condition
CONTROL_PLANE_IDENTITY_LATCH_NOT_ACTIVATED The deployment has not been finalized
CONTROL_PLANE_IDENTITY_LATCH_INVALID The presented identity does not satisfy the latch contract
CONTROL_PLANE_IDENTITY_LATCH_IMMUTABLE A change to a latched value was attempted

A node's registration carries the cp_instance_uuid it enrolled against, so a node cannot silently attach to a different control plane that answers at the same endpoint.

The control plane prepares, and the node calls

The control plane opens no connection into your infrastructure. It records intent, prepares assignments, and waits; xratud calls out to collect them and reports back on the same connection it opened.

xratud -> control plane    register, heartbeat, pull, watch, ack, report
control plane              records and prepares, and initiates nothing

Two properties follow from that direction. Your infrastructure needs no inbound path, so a node behind a restrictive network policy works as long as it can reach the endpoint outbound. And nothing is carried out of your organization by the control plane: what leaves is what a node chose to send, which is metadata, digests and object references. Bodies and artifact bytes stay where the node wrote them. See The tenant byte rule.

A control plane operated by someone else therefore holds the authority to decide and no route into the infrastructure its decisions apply to.

What a node contributes

A node reports facts about itself: provider, region, cluster, namespaces, capacity, health, and the digests it produced. Those are inputs to control-plane decisions. The decision itself is recorded centrally, which is why placement is answerable from the control plane even when the node that ran the work is gone.

Node behaviour comes from the assignment it was given and the runtime profile the control plane delivered, so the question "why is this node doing this" resolves to a document the control plane holds.

Reading the trail during an incident

Question Where the answer is recorded
What should this node be running The assignments on the ledger scoped to its node id
Which policy was in force effective_policy_digest on the assignment, and the snapshot it digests
Which code was pinned The resolver snapshot's block identity, capsule digest and distribution artifacts
Which node held the runtime The ownership lease and its fence epoch
What the node observed fence_token and observed_generation on its acknowledgement
What was produced Evidence lineage, object references and reported digests

See The correlation tuple for the fields that join those records to what the kernel emitted.