Operations
Bootstrap from zero
Section titled “Bootstrap from zero”kvm install config.svc # or build from sourceconfig.svc config generate bootstrap-dev > config.yaml # pick a profileconfig.svc config generate apikeys > apikeys.yamlconfig.svc server -f config.yamlcurl -H "X-Api-Key: $KEY" http://localhost:7123/hivesStorage needs:
- Single node — a writable directory for the bbolt snapshot store (
storage.mode: bbolt). - HA — an operator-run etcd cluster (3 or 5 nodes) plus leader election (
ttl: 15s). The reconciler runs on the leader; reads and writes are served by every instance. - Postgres break-glass source — one-time DDL:
config.svc config generate pgsource | psql …(creates the overrides table + NOTIFY trigger).
Seed content by pointing a localdir/fs source at a folder of flat-path documents (see Configuration files), or use git sources for real deployments.
Migration helpers:
config.svc import-legacy— one-shot conversion of legacy clusterstore/customerstore trees to the hive layout.config.svc migrate— applies major-schema-version transforms.
The client CLI is kis config / kis sd:
kis config hiveskis config get tenant acme:forge:prod:tenant-a:iamkis config explain tenant acme:forge:prod:tenant-a:iam # per-field provenancekis config set cluster dc1:main:iam --file node.yamlkis config watchkis sd serviceskis sd instances iamServer admin subcommands on the binary itself: server, config list|generate, import-legacy, migrate, explain, version.
Watch and reload behavior
Section titled “Watch and reload behavior”- Per-backend watches (fsnotify / git ref-poll + webhook / etcd watch / postgres LISTEN-NOTIFY) feed the reconciler; there is no full-tree rescan on a healthy path.
- Subscribers resume by
Last-Event-Id; a cursor that is too old getsfull_resync. - The service-side client reconnects forever with jittered exponential backoff and serves its bbolt last-known-good cache meanwhile.
- Read-after-write lag is typically hundreds of milliseconds; use
If-Min-Versionwhen a caller must observe its own write.
Break-glass writes
Section titled “Break-glass writes”Writes route to the highest-priority writable source (postgres/etcd/localdir). Use:
X-Reason— flows into audit and intoexplainprovenance.X-Schedule-Revert-At— enqueues an audited auto-revert; the revert fails loudly if state diverged in the meantime.alert_on_writeon the source — pages when anyone writes through it.
Failure modes
Section titled “Failure modes”Everything fails closed by design:
| Symptom | Cause |
|---|---|
| Writes return 503 | Audit sink (the platform audit service) unreachable — writes are never buffered locally. Dev: leave audit.endpoint empty for a no-op emitter |
| Boot error naming a source | Unreachable source, empty owns, writable: true on fs/git, or owns: ["**"] on the tenant hive |
| Whole source fails with a file-naming error | A YAML file without a top-level hives: key (the legacy-layout mistake) |
| Snapshot missing / write 422 | CUE validation failure — the metric carries hive, path, and CUE path |
400 invalid_path | Predefined-level violation (e.g. environment not in dev/uat/prod) |
| 409 on write | If-Match version conflict |
Observability is OpenTelemetry-only (infinity_config_* / infinity_discovery_* metric namespaces) — there is no /metrics endpoint.