Commit 0ff0ae3
feat(server): readiness witness and bounded shutdown (RFC 0049) (#612)
feat(server): readiness reports counts, the inventory names the quarantined, a thread keeps the deadline
From review: GET /readyz no longer lists graph ids, which are topology
behind the authenticated GET /graphs; that route gains `quarantined`,
derived from the ledger's applied graphs minus the registry, with sidecar
graphs intersected with the applied set so a sidecar for a graph the
revision does not name is never a phantom. The shutdown watchdog is an
operating-system thread, so a blocked runtime cannot postpone it, and the
signal listener is spawned before any graph opens, so the bound covers
startup. The flag wins over OMNIGRAPH_SHUTDOWN_GRACE_SECONDS, which is read
only when the flag is absent. openapi.json regenerated.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015cD8PEeUfrzpqYuU1jaZBq
feat(server): readiness witness and bounded shutdown (RFC 0048)
`GET /readyz` reports whether a replica is serving or draining, the
applied `config_digest` it booted from (`booted_serving_digest`), the
ledger revision and CAS it read, and its served and quarantined graphs; it
answers 503 once shutdown has begun while `/healthz` stays 200.
`--shutdown-grace-seconds` (or `OMNIGRAPH_SHUTDOWN_GRACE_SECONDS`, default
25) puts one deadline on graceful shutdown: readiness turns off at the
signal, in-flight requests drain, and at the deadline the process exits 2
with the unfinished work logged. `ServingSnapshot` carries the boot facts;
`ServerConfig` gains `witness` and `shutdown_grace`; `openapi.json` is
regenerated.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015cD8PEeUfrzpqYuU1jaZBq1 parent 1609ac3 commit 0ff0ae3
14 files changed
Lines changed: 597 additions & 15 deletions
File tree
- crates
- omnigraph-api-types/src
- omnigraph-cluster/src
- omnigraph-server
- src
- tests
- docs
- dev
- releases
- rfcs
- user
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1065 | 1065 | | |
1066 | 1066 | | |
1067 | 1067 | | |
| 1068 | + | |
| 1069 | + | |
| 1070 | + | |
| 1071 | + | |
| 1072 | + | |
| 1073 | + | |
| 1074 | + | |
| 1075 | + | |
| 1076 | + | |
| 1077 | + | |
| 1078 | + | |
| 1079 | + | |
| 1080 | + | |
| 1081 | + | |
| 1082 | + | |
| 1083 | + | |
| 1084 | + | |
| 1085 | + | |
| 1086 | + | |
| 1087 | + | |
| 1088 | + | |
| 1089 | + | |
| 1090 | + | |
| 1091 | + | |
| 1092 | + | |
| 1093 | + | |
| 1094 | + | |
| 1095 | + | |
1068 | 1096 | | |
1069 | 1097 | | |
1070 | 1098 | | |
| |||
1611 | 1639 | | |
1612 | 1640 | | |
1613 | 1641 | | |
| 1642 | + | |
| 1643 | + | |
| 1644 | + | |
| 1645 | + | |
| 1646 | + | |
1614 | 1647 | | |
1615 | 1648 | | |
1616 | 1649 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
44 | 56 | | |
45 | 57 | | |
46 | 58 | | |
| |||
271 | 283 | | |
272 | 284 | | |
273 | 285 | | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
274 | 290 | | |
275 | 291 | | |
276 | 292 | | |
| |||
457 | 473 | | |
458 | 474 | | |
459 | 475 | | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
460 | 484 | | |
461 | 485 | | |
462 | 486 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
31 | 73 | | |
32 | 74 | | |
33 | 75 | | |
| |||
81 | 123 | | |
82 | 124 | | |
83 | 125 | | |
84 | | - | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
85 | 130 | | |
86 | 131 | | |
87 | 132 | | |
| |||
114 | 159 | | |
115 | 160 | | |
116 | 161 | | |
117 | | - | |
| 162 | + | |
118 | 163 | | |
119 | 164 | | |
120 | 165 | | |
| |||
0 commit comments