state-hub/workplans/STATE-WP-0078-ops-run-read-projection.md
codex 3cb256ef5c
All checks were successful
CI Smoke / host-smoke (push) Successful in 0s
CI Smoke / container-smoke (push) Successful in 1s
fix(workplans): adopt ADR-007 derived identifiers for unregistered records
These workplans exist only in the retired local hub. Their random pre-ADR-007
identifiers are refused by C-06 as stale references, so they cannot be
registered. Deriving from the canonical record id takes no identity from
anything: central does not hold them and the old ids die with the cache.

Records central already holds were deliberately left untouched.

Refs CUST-WP-0068-T06

Assistant: claude-code
Assistant-Model: opus
Assistant-Process: 2583210@bnt-lap001
Assistant-Session: f2bff2d5-e9b2-4338-92ca-10282a927006
2026-08-25 20:22:27 +02:00

3 KiB

id type title domain repo status owner topic_slug priority created updated depends_on related state_hub_workstream_id
STATE-WP-0078 workplan Ops run read projection for fleet visibility infotech state-hub finished codex state-hub low 2026-08-03 2026-08-08
ACTIVITY-WP-0026
ACT-ADR-005
STATE-WP-0074
81ed67ec-e3f8-52cd-bce9-4432ff9095cb

STATE-WP-0078 — Ops run read projection

Origin

ACT-ADR-005: State Hub remains the work-record read model on coulombcore. It may project activity-core ops_run state for fleet ops UI without becoming the claim authority.

Goal

Expose open/failed/recent ops runs to operators and agents via State Hub summary/API read paths, fed from activity-core (edge/NATS/pull) — so coulombcore-oriented agents see automation health without claiming work.

Tasks

T01 — Contract with activity-core

id: STATE-WP-0078-T01
status: done
priority: medium
state_hub_task_id: "ff4f5ae8-67fb-5fe2-a5cf-75c551cfdeef"

Agree payload shape with ACTIVITY-WP-0026 (id, definition, target_repo, state, lease, updated_at, last_error). Document whether pull (hub polls actcore) or push (actcore posts progress summary) is v1.

Done when: short contract note in docs/ or linked from ACT-ADR-005.

Implemented in docs/ops-run-read-projection.md: v1 is an authenticated, cached pull from activity-core GET /ops-runs; activity-core remains the only claim/lease/completion authority.


T02 — Read API + summary field

id: STATE-WP-0078-T02
status: done
priority: medium
state_hub_task_id: "07deec86-26aa-5dc4-8605-f9b704d33151"

Minimal:

  • GET /ops-runs/summary or extend /state/summary with ops_runs: { open, claimed, failed_24h }
  • No claim/complete endpoints on State Hub

Done when: MCP/summary consumers can show stuck automation.

Implemented GET /ops-runs/summary and the /state/summary.ops_runs projection, including open/claimed/failed-24h counts, SLA-stuck count, bounded run details, and stale/unavailable behavior. No write endpoints exist under State Hub's /ops-runs route.


T03 — Edge/federation notes

id: STATE-WP-0078-T03
status: done
priority: low
state_hub_task_id: "63e14866-4804-5c45-8bab-46d949adfd00"

Document coulombcore vs railiance: claim on railiance actcore-api; visibility may lag if edge relay down — alert preference.

Done when: cluster-operating-model or ops doc updated.

Documented in docs/cluster-operating-model.md and docs/ops-run-read-projection.md.

Acceptance

  • Hub does not claim ops_runs
  • Operators see automation backlog on primary hub views
  • No Forgejo/Gitea dependency

Residual handoff

Production deployment wiring is tracked as State Hub intake 019fe359-debb-71a6-958c-b8f4ac3574a0 (origin: residual, origin_ref: STATE-WP-0078). It covers the private activity-core URL, OpenBao/ESO token injection, rollout, and live fleet verification.

Out of scope

  • Moving claim API to State Hub
  • Workplan file generation for daily ops