Files
mesh-catalog/modules/mesh-healers/README.md
T
jschoubben 9dd27d2edb Re-arm every running settle from the attempts kept when the healers start, so a restart loses no wake (issue 1952)
A settle that ended while they were down is judged at once. The README says the week-long bucket age is the deleter of would and attempts for this release.
2026-10-29 21:49:46 +01:00

44 lines
2.8 KiB
Markdown

# mesh-healers
Holds the seat `mesh-healers` (novox/hq ADR 0564 §7, §8): the mesh's healers, moved out of the controller. Go, one
binary (`cmd/mesh-healers`), served by a runtime of its own on its own bus account (`runs-as`).
## What it does
It hears the condition keeper's `condition-raised` and `condition-changed` (seat `mesh-conditions`) on a durable
consumer. A condition whose kind a healer answers is acted on within the healer's budget, its settle and the mesh-wide
brake (twelve acts an hour). A repair is a call of the seat or tool that owns the act: H3 asks the grants part's
`grants_assert` for the module whose consumer is gone. H4 (the controller's own consumer) and H5 (the provider's own
repair) are registered and run elsewhere.
Each act is begun by a create of its key in `attempts` before it is made and finished after, so a holder that dies
mid-act has spent it and a second instance cannot begin it again. The condition keeper writes the condition's
`tried`, resolver and escalation from `attempts`; a healer writes no condition.
**Only once the controller's lease names no controller.** Until the write that hands the lease away, each act it would
take is written to `would`, never to `attempts`: it counts for no budget, settle or brake and reaches no condition.
Both buckets age as a whole, each key a week after its last write: the runtime gives a bundle no time to live per
key, so the bucket's age is the deleter for this release. The end of a settle and the end of S15's fortnight wake the
healers through an in-process timer, armed by the act; at start, once the lease is first read, every settle still
running is re-armed from `attempts` and one that ended while they were down is judged at once, and the hand-act log's
watch hands over every entry again, which re-arms S15. So a restart loses no wake.
S15: it watches the controller's hand-act log and writes `healer-wanted` for a cause repaired by hand twice within a
fortnight; a drill and a person's decision by design never count.
## What it keeps
- `mesh-healers_attempts`: every act and escalation, kept a week (the bucket's age).
- `mesh-healers_would`: the newest act it would take per healer and condition while the controller holds the lease,
kept a week (the bucket's age); nothing else deletes it, and nothing is written there once the lease is handed away.
- `mesh-healers_findings`: the brake, its own blindness, and S15.
## Its verbs and tools
- `mesh-healers.healers`: the registry, the acts of the last days, the would-acts, the brake, whether it acts and why;
`recount=true` counts the hand-act log again.
- `mesh-healers.heal`: one act now on an open condition, by key and why.
- `mesh-healers.drill`: refused until the hand-act log's home is delivered (issue 1953), naming `mesh-controller.drill`.
- `healers_findings`, `healers_would`: the reads of its buckets.