feat: expose institutional architecture and runtime state

This commit is contained in:
2026-08-01 17:48:37 +02:00
parent 05ce4dc8ec
commit c241085806
10 changed files with 906 additions and 10 deletions
+19
View File
@@ -63,3 +63,22 @@ def test_module_operational_check_failure_is_isolated() -> None:
assert result["state"] == "error"
assert "secret detail" not in result["detail"]
def test_shared_runtime_cluster_missing_replicas_blocks_readiness() -> None:
check = routes._runtime_cluster_check(
{
"available": True,
"state_profile": "shared",
"nodes": [
{"role": "api", "state": "active", "stale": False},
{"role": "worker", "state": "active", "stale": True},
],
"expected": {"api": 2, "worker": 1},
"active": {"api": 1, "worker": 0},
"recovery": {"requires_attention": 1},
}
)
assert check["state"] == "error"
assert check["readiness_critical"] is True
assert check["metrics"]["recovery_required"] == 1