Ask at most three at a time, wait out a refusal, need a router, and act only on a claimed open ask, as the review asked (hq ADR 0259)

This commit is contained in:
jochen
2026-10-09 16:22:34 +02:00
committed by jschoubben
parent 8de4dc7951
commit 744b0b9162
10 changed files with 384 additions and 33 deletions
+7 -7
View File
@@ -680,11 +680,11 @@ func walkWaitingWords(w waitFacts, in time.Duration, severity conditions.Severit
}
// waitingNeeds is what the operator does about a walk waiting past its urgent bound: nothing before it.
// Start and Stop are asked of the operator (novox/hq ADR 0259), so the words do not say where: the router
// says where each can be answered.
// Start and Stop are also asked of the operator (novox/hq ADR 0259); the condition's own words keep saying
// where they are given without a channel, and the ask's text drops that (askText).
func waitingNeeds(severity conditions.Severity) string {
if severity == conditions.Urgent {
return "start it, or stop it."
return "start it, or stop it, " + FromMeshMCPServer
}
return ""
}
@@ -717,8 +717,8 @@ func moduleNeeds(node string, rs []inventory.ResourceHealth) string {
}
}
if unit != "" {
// Asked of the operator (moduleActions): the router says where it can be answered.
return fmt.Sprintf("restart its service %s on %s.", unit, node)
// Also asked of the operator (moduleActions); the ask's text drops where (askText).
return fmt.Sprintf("restart its service %s on %s %s", unit, node, FromMeshMCPServer)
}
return ""
}
@@ -824,11 +824,11 @@ func stalledWords(l stalledLine, o conditions.Observation) (headline, explanatio
Arguments: map[string]string{"id": l.ID, "why": ""}}
switch held {
case "held":
needs, actions = "release it, or stop it.", []conditions.Action{release, stop}
needs, actions = "release it, or stop it, "+FromMeshMCPServer, []conditions.Action{release, stop}
case "ready", "checked":
needs = "merge its pull request, or close it."
default:
needs, actions = "stop it.", []conditions.Action{stop}
needs, actions = "stop it "+FromMeshMCPServer, []conditions.Action{stop}
}
}
return fmt.Sprintf("Delivery of %s %s %s", name, held, long),