Skip to content
Opod

Get started

Architecture

What runs where in a cluster with opod, how a plan becomes pods, and what keeps working when the control plane is down.

The control plane manages; core serves. Requests never pass through the control plane.

For why it is built this way, and what each choice costs, see Design decisions.

 clients ──► endpoint Service ──► leader (core) ──► workers (core + engine) ──► GPUs
                                    ▲  mounted plan, keys, policy
                                    │  (Kubernetes Secret + ConfigMap)
 operators ──► opodcp (API + console) ──► Kubernetes API ──► Deployments, LeaderWorkerSets, Jobs
                 │        ▲
                 ▼        │ probe readings (VRAM, host facts)
            your Postgres  per-vendor telemetry DaemonSets

The request path of one endpoint

Pick a failure and watch where requests go

The leader scores each live worker from its heartbeat (in flight + queue depth) and sends the request to the lowest. The control plane is never asked.
request pathconfiguration onlyfailed / cut

What runs in the cluster

ObjectCountPurpose
opodcp Deployment1 (or more, see High availability)API, console, controller loops
Pre-install preflight Jobonce per install or upgraderefuses a cluster that would half-install
GPU telemetry DaemonSetsone per vendor, on nodes labelled opod.io/gpu-vendormeasure every card and push the readings to the control plane every 20 s
Device pluginswhen absentNVIDIA, AMD, Intel, Tenstorrent; optional RDMA and Multus
LeaderWorkerSet controllerchart dependency, on by defaultlands a multi-pod gang as one unit
Per endpoint1 leader, N workers, optional doorsserving
Per endpoint1 plan ConfigMap, 1 auth Secretwhat the leader reads

Optional, off by default: KEDA, a provided Postgres (CloudNativePG), a provided NATS, the cell door, a shared KV store (Valkey).

From plan to pods

  1. You write a plan (console, API, or opodcp apply).
  2. The planner judges it: engine and vendor support, model fit against measured VRAM, the KV cache the workload needs, host memory and disk for KV tiers, licence ceiling, team quota, node taints, parallelism rules. A refusal returns an E-… code with alternatives and writes nothing.
  3. The plan is stored with a new revision, and a run starts. A verified rollout runs: validate → prefetch → apply → converge → probe → fabric proof → smoke → canary → eval → promote.
  4. The executor renders Kubernetes objects with Server-Side Apply, in its own namespace, on objects it labels.
  5. The reconciler keeps the cluster matching the stored plan. It never restarts a serving pod on its own because a template changed; that waits for a rollout.

Identity and ownership

Objects belong to an endpoint by id, not by name: they are named opodcp-ep-<name>-<id6> and selected by the label opod.io/endpoint-id. The one exception is the leader's Service, opodcp-ep-<name>, which stays stable across re-creates because it is the in-cluster hostname workers join and clients call. A re-created endpoint with an old name never adopts the old one's objects. Objects of an endpoint the store does not know are reported as foreign and never touched.

What survives an outage

The leader serves from its mounted plan, auth snapshot and policy. Those are Kubernetes objects that the kubelet keeps in the pod.

LostEffect
Every opodcp replicaServing, routing and key checks continue. With autoscaler.adapter=keda, scaling and wake-from-zero continue inside the capacity the control plane approved. New endpoints, plan edits and rollouts wait.
The databaseCalls answer 503 E-DB-UNREACHABLE and change nothing; the control plane reconnects by itself. Serving continues.
A leader podKubernetes restarts it (about 10 s). With front doors on, requests keep flowing.
A workerThe leader routes to the others. The reconciler replaces the pod.
A nodeIts workers stop; the leader routes to the workers left. Evacuate the node to move its workers through rollouts. A leader on a node that may no longer hold one is pinned to another node.

Key revocation does not need the control plane either. See Revoke a key with the control plane down.

What the control plane talks to

DirectionPeerWhy
OutKubernetes API servereverything it manages; calls to a leader ride the API server's Service proxy
OutYour Postgresits only durable store
Outghcr.io or your mirrorimage digests and signatures
Out (from pods)Hugging Face or your mirrorprefetch Jobs and workers fetch weights; a prefetch checks a published model signature
Out, optionalyour sinksusage, logs, metrics, traces, alerts, NATS, Vault, object store
Inoperators, scriptsAPI and console on port 8080
Intelemetry podsprobe readings

Nothing calls home. The licence is verified offline.

Scale

One cell is one cluster. To manage more clusters, run one control plane per cluster and a fleet control plane over them. See Several cells.

Last updated · Source: content/docs/get-started/architecture.mdx · View as Markdown