Component topology¶
Nothing in Xratu discovers anything. Every link between components is either a configured endpoint or a declared identity, and a component that cannot resolve its peer fails closed rather than falling back. Knowing which link is which is what lets you diagnose a day-0 step that stalls.
There are four links, and only one of them carries execution.
flowchart TB
CLI["CLI<br/>your workstation"]
CP["CONTROL PLANE<br/>HTTP API, port 8080"]
DP["DATA PLANE NODE<br/>xratud"]
RT["PROJECT RUNTIME<br/>kernel and cells"]
SA["SPIRE AGENT<br/>node-local DaemonSet"]
CLI -- "profile endpoint" --> CP
DP -- "registers, pulls, reports" --> CP
DP -- "private control lane<br/>mutual TLS" --> RT
DP -- "Workload API<br/>unix socket" --> SA
RT -- "Workload API<br/>unix socket" --> SA
Every arrow points at the component that is dialled. The control plane never dials a node, and no client dials a kernel.
The CLI reaches the control plane by configured endpoint¶
The CLI holds named profiles, and the active profile carries the control-plane endpoint and the token used with it. Nothing is auto-detected: if no endpoint is configured, commands fail rather than guessing at a local service.
Where an installation needs the endpoint written into generated files, the
resolution order is explicit: the value passed on the command line, then
CP_ENDPOINT, then XRATU_CP_ENDPOINT, then the active profile's endpoint.
How the endpoint is exposed in the first place is a deployment decision, and for a self-hosted cluster a port-forward is the recommended default rather than a public ingress. See Endpoint resolution, Profiles and API exposure options.
A node reaches the control plane, and only in that direction¶
A node is configured with two things about the control plane: a base_url and
a trust_bundle_ref. From there the relationship is entirely node-initiated.
It registers, heartbeats, pulls assignments, acknowledges them, and reports
status, events, logs and evidence. The control plane publishes desired state
and waits.
This is why there is no inbound path to open. A node needs to reach the control plane; the control plane needs no route back. A node behind a restrictive network policy works as long as it can make outbound calls to the endpoint, its registry, its bucket and its identity provider.
The pull relationship is versioned on both sides, and the node's half is declared in its bootstrap profile:
spec:
control_plane:
base_url: https://control-plane.example.internal
trust_bundle_ref: bootstrap-trust://default/v1
pull:
protocol_version: dataplane.v1
assignment_schema_version: assignment.v1
heartbeat_seconds: 15
max_assignments_per_pull: 4
max_worker_slots: 32
A protocol mismatch fails closed; there is no silent downgrade to an older shape.
Before any of that, the node must have an identity. Joining is a distinct step
from running: an init container performs the bootstrap join, presenting an
invitation code together with the installation and instance identifiers and its
node label. The control plane validates the invitation's scope and returns a
seed, which is persisted alongside the node's identity state under
/var/lib/xratu/identity. That durable state is what makes a restart a
continuation rather than a new node. See
Enrollment and
Identity continuity.
A node reaches its kernels over a private lane¶
The link from a node to a project runtime is not the pull relationship in miniature. It is a private gRPC channel over HTTP/2 with mandatory mutual TLS, generated from one checked-in protocol definition that both planes build from. Caller identity is derived from the verified TLS peer certificate and never from anything in the request body, so a caller cannot assert who it is.
Both ends are named, and both names are declared rather than discovered:
node spiffe://xratu/dataplane/<dataplane_node_id>
project runtime spiffe://xratu/workspace/<workspace_uuid>/runtime/<runtime_instance_id>
The node verifies which runtime it reached, not merely that a certificate was signed. The control plane provisions the expected name, the identity registration issues to match, and the kernel compares its certificate against it. See Node attestation and Trust bundles and revisions.
The channel carries two lanes with deliberately different lifetimes. The command lane is synchronous request and response, re-admitted on every call. The continuity lane is durable, sequence-cursored and digest-chained, and the kernel pushes on it as evidence is appended, with the node acknowledging sequences on the same stream; reopening from a sequence resumes exactly where a dropped stream left off. A polled form of the same semantics exists for reconnect.
What the node may say on the command lane is an allowlist, not a general capability:
runtime.ping runtime.diagnostics.set
runtime.health runtime.diagnostics.clear
runtime.status.snapshot runtime.diagnostics.snapshot
runtime.flush_evidence runtime.drain_prepare
runtime.rotate_identity runtime.drain_commit
None of these execute application work. The run operations that do are a kernel-native surface reached from inside a cell, and the operator lane refuses them explicitly.
So this link carries deployment, supervision and evidence, not runs. After a node has deployed a project runtime and confirmed it ready, that runtime's kernel executes the project's agents and workflows on its own, and none of that traffic crosses this link or reaches the control plane.
Acceptance is re-evaluated per request rather than once per session: identity, protocol compatibility, trust-bundle agreement and ownership all have to hold each time. These refusals are terminal and are never retried:
| Refusal | Meaning |
|---|---|
peer_identity_rejected |
The certificate does not match the expected SPIFFE name |
trust_bundle_digest mismatch |
The caller is outside the kernel's accepted trust revision |
stale_fence |
The caller holds an ownership fence that has been superseded |
runtime_session_non_owner |
The caller is not the current owner of this runtime |
runtime_session_not_found |
No such runtime session exists |
unsupported_on_operator_lane |
The operation is not admissible on this lane |
unsupported_operator_command |
The command is outside the allowlist |
Both ends of that lane hold certificates from a node-local agent¶
The certificates presented on the control lane are served by a SPIRE agent
running on the node as its own DaemonSet. xratud and each project runtime
kernel reach it over a Unix socket published into their pods by a CSI driver:
mount /run/spiffe/workload-api
env SPIFFE_ENDPOINT_SOCKET=unix:///run/spiffe/workload-api/spire-agent.sock
This link stays on the node. Both consumers dial the agent as ordinary workloads, and the agent attests each one against a registration entry before issuing it a certificate.
The agent is deployed by the installation: prepare renders the substrate into
the bundle, and apply applies it before it scales nodes, so the socket is
present before the first process needs an identity. See
The SPIRE agent.
Only the current owner may act¶
More than one node can be capable of reaching a runtime, so ownership is explicit. Each project runtime instance has one owning node at a time, and only that owner may send operator commands or advance the acknowledgement cursor on the return lane. Ownership moves deliberately, and a channel held by a previous owner cannot outlive the session that owned it.
How the scopes nest¶
The links above connect components. These names describe what those components contain, and they are the identifiers you will see in every command and record.
Organisation is the administrative tenancy boundary above the control plane. Tenancy must exist before any node does.
Workspace is the namespace-style isolation scope for workloads, routing and policy attachment. Workspace isolation is enforced at routing, dispatch and reporting authorisation, not at enrolment.
Pool groups nodes for placement within an organisation. A pool is created before an installation or an invitation refers to it.
Installation is one deployment target, named by dp_install and sized by
dp_count.
Node is one running xratud instance, with its own durable identity.
Enrollment identity is node-scoped and never workspace-scoped, which is why one
node can serve work from several workspaces.
Project runtime is one replica of a deployed project, with its own kernel.
Every record crossing these boundaries carries the same correlation tuple:
That is what lets one piece of work be followed from an API call through to a kernel decision. See The correlation tuple.
What this predicts when something fails¶
Because each link is configured rather than discovered, a stall has a small number of causes and each points at one link.
A CLI command that cannot reach the API is a profile or exposure problem. A node that never appears is a bootstrap join problem: endpoint reachability, the invitation and its scope, or the token injection. A node that appears and then goes quiet is a pull or protocol-compatibility problem. A project runtime that never becomes ready is a kernel-lane problem: identity, trust bundle revision or ownership.
Verifying and troubleshooting day-0 turns that division into checks.