llmgw stop, start and restart act on the whole system

Issue #3 asked for commands to stop and start the system, and 05aa21c gave
only one machine's services. Now:

- llmgw stop sets serving.stopped in the cluster's settings, live: the
  reconciler wants every model at no replicas, freeing every GPU, and the
  gateway answers every POST under /v1/ with 503 system_stopped. The control
  planes, agents and mirror keep running, and no model's definition changes.
- llmgw start clears it; every model is placed again as it asks.
- llmgw restart has every agent restart over its stream (RestartAgent), then
  the other control planes over ssh, standbys before a leader, then this
  one; engines keep serving.
- llmgw status is the cluster's summary, saying when it is stopped.

One machine's services moved to llmgw service status|start|stop|restart.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Ilker ManapandClaude Opus 5.5 committed 2026-10-07 18:01:45 +02:00
1 parent 05aa21c4d4
commit 7245dbe1dd
29 files changed
+891 -254

No files matched your search

+51
View File
@@ -17,6 +17,9 @@
}
],
"tags": [
{
"name": "agents"
},
{
"name": "audit"
},
@@ -100,6 +103,38 @@
}
],
"paths": {
"/api/v1/agents/restart": {
"post": {
"operationId": "postAgentsRestart",
"summary": "Have every node's agent start again; their engines keep serving",
"tags": [
"agents"
],
"parameters": [
{
"$ref": "#/components/parameters/Actor"
}
],
"responses": {
"200": {
"description": "OK",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/AgentRestartView"
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"default": {
"$ref": "#/components/responses/Error"
}
}
}
},
"/api/v1/audit": {
"get": {
"operationId": "getAudit",
@@ -3554,6 +3589,18 @@
}
}
},
"AgentRestartView": {
"type": "object",
"description": "AgentRestartView names the nodes whose agents were told to restart.",
"properties": {
"nodes": {
"type": "array",
"items": {
"type": "string"
}
}
}
},
"CanaryPercentRequest": {
"type": "object",
"description": "CanaryPercentRequest changes the share of a model's requests its canary takes.",
@@ -5928,6 +5975,10 @@
},
"description": "Judges are the guardrails' judge models with something wrong."
},
"stopped": {
"type": "boolean",
"description": "Stopped says the operators have stopped the service (llmgw stop): no model runs, and requests for one are answered 503."
},
"guard_off": {
"type": "boolean",
"description": "GuardOff says the guardrails are turned off (guard.enabled: false): no request is checked, whatever the policies say."