omnigraph/docs/user
Andrew Altshuler 6144bb18d6
feat(cli): cluster-managed maintenance addressing + init signpost (RFC-010 Slice 3) (#221)
* feat(cluster): cluster_root_for_graph_uri detection helper (RFC-010 Slice 3)

Public helper the CLI uses to refuse `init` into a cluster-managed location:
given a graph storage URI of the cluster layout (`<root>/graphs/<id>.omni`),
return the cluster root if `<root>` holds `__cluster/state.json`, else None.

Cheap by construction — a URI that doesn't match the `<root>/graphs/<id>.omni`
shape returns None with zero I/O, so ordinary `init` targets never probe
storage. Works for file:// and s3:// via the storage adapter. Adds two
ClusterStore accessors (`display_root`, `has_state`).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* feat(cli): cluster-managed maintenance addressing + init signpost (RFC-010 Slice 3)

Two cluster-graph-aware CLI behaviors, sharing the cluster-resolution path.

Maintenance addressing. `optimize`/`repair`/`cleanup` gain
`--cluster <dir|s3://…> --cluster-graph <id>`, which resolves the graph's
storage URI from the served cluster snapshot (the same truth a `--cluster`
server boots from — `read_serving_snapshot*`) and opens it embedded. The
operator no longer hand-types `<storage>/graphs/<id>.omni`. A distinct flag is
required because the global `--graph` is `requires = server` and means a remote
multi-graph id. clap enforces both-or-neither and exclusion with the positional
URI / `--target`; an unserved graph errors loudly, pointing at `cluster apply`.

init signpost. `init` refuses a cluster-managed positional path (the
`<root>/graphs/<id>.omni` layout where `<root>` holds `__cluster/state.json`,
detected by `cluster_root_for_graph_uri`) and points at `cluster apply` — graphs
in an established cluster are created with ledger/recovery/approvals, not by
hand. The check is gated on the path shape, so ordinary `init` does no extra I/O
and existing pre-apply cluster-graph inits are unaffected.

planes guard remediation now also mentions `--cluster … --cluster-graph …`
(the two Slice-1 guard-string tests track it). Docs updated (cli-reference
Command planes, maintenance.md, cluster.md §7); the stale "no S3-hosted cluster
directories" limitation is dropped (RFC-006 landed it).

Tests (cli_cluster.rs, reusing the apply-a-cluster fixture): resolve by id,
unknown-id error, `--cluster` requires `--cluster-graph`, init refusal +
signpost, and ordinary init still works.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* fix(cli): resolve cluster graphs from the state ledger, not the serving snapshot

Addresses the Greptile review on #221. `read_serving_snapshot*` does
all-or-nothing serving validation — recovery-sidecar checks plus a digest
verify of every catalog payload (query .gq, policy blobs). Using it to resolve
a maintenance target coupled `optimize`/`repair`/`cleanup` to the readiness of
unrelated resources: a single corrupt policy blob, or a pending recovery sweep,
would block the command before it could touch the graph — worst for `repair`,
the tool you reach for *when the cluster is degraded*.

Add `omnigraph_cluster::resolve_graph_storage_uri(cluster, graph_id)`: read the
state ledger, confirm the graph is in the applied revision, return
`graph_root(id)` — the URI is deterministically derivable, no catalog
validation. The CLI's cluster resolver now calls it.

Test: `optimize --cluster … --cluster-graph …` still resolves after the catalog
payloads (`__cluster/resources/`) are removed — the ledger-only path is not
blocked by degraded/unrelated catalog state.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-14 02:52:21 +03:00
..
audit.md docs(cli): the two config surfaces + the operator file reference 2026-06-11 20:32:04 +03:00
branches-commits.md fix: optimize publishes compaction; recovery roll-back converges manifest (#141) 2026-06-08 02:50:12 +03:00
changes.md docs: split user and developer docs (#93) 2026-05-15 03:45:22 +03:00
cli-reference.md feat(cli): cluster-managed maintenance addressing + init signpost (RFC-010 Slice 3) (#221) 2026-06-14 02:52:21 +03:00
cli.md feat(cli)!: unified load command; deprecate ingest as an alias 2026-06-11 04:18:00 +03:00
cluster-config.md feat(cluster): the storage: root — state, catalog, and graph roots relocatable 2026-06-11 14:28:04 +03:00
cluster.md feat(cli): cluster-managed maintenance addressing + init signpost (RFC-010 Slice 3) (#221) 2026-06-14 02:52:21 +03:00
constants.md feat(engine): indexed graph traversal (#149) 2026-06-09 18:09:13 +02:00
deployment.md test(cluster,server): gated object-storage cluster e2e + CI wiring + docs 2026-06-11 15:56:40 +03:00
embeddings.md Rename repo terminology to graph (#118) 2026-05-24 16:46:00 +01:00
errors.md docs: rename runs.md/runs.rs → writes and repoint all references (#131) 2026-05-30 23:20:56 +02:00
index.md docs(cluster): operator how-to guide for deploying and managing clusters 2026-06-10 22:10:19 +03:00
indexes.md feat(engine): indexed graph traversal (#149) 2026-06-09 18:09:13 +02:00
install.md Add Windows release binaries (#127) 2026-05-30 14:23:40 +02:00
maintenance.md feat(cli): cluster-managed maintenance addressing + init signpost (RFC-010 Slice 3) (#221) 2026-06-14 02:52:21 +03:00
policy.md feat(cli)!: unified load command; deprecate ingest as an alias 2026-06-11 04:18:00 +03:00
query-language.md (feat) convert engine call sites to &dyn TableStorage; demote legacy TableStore methods to pub(crate) (#86) 2026-06-09 23:03:08 +02:00
schema-language.md schema: HTTP allow_data_loss exposure + e2e drop coverage (MR-694 follow-up) (#107) 2026-05-19 01:56:46 +03:00
schema-lint.md docs: split user and developer docs (#93) 2026-05-15 03:45:22 +03:00
server.md test(cluster,server): gated object-storage cluster e2e + CI wiring + docs 2026-06-11 15:56:40 +03:00
storage.md Recovery liveness, storage fault-injection matrix, and one storage implementation over object_store (#203) 2026-06-13 11:20:08 +02:00
transactions.md docs: drop ./ path prefixes; document query discovery 2026-06-11 01:33:30 +03:00