D-4, D-5, D-6: the bootstrapped and test seat definitions are the contracts' files at milestone G's heads
The catalogue's tests of the retired delivery verbs go with them. Builds: design 47 G §203, §309, §365, §302, §337, §336, §389, §390, §83, §307, §308, §260, §349, §375 Claude-Session: https://claude.ai/code/session_01JG73KEq4zoDfM9WtYpcQgZ
This commit is contained in:
@@ -1,66 +1,11 @@
|
||||
package catalogue
|
||||
|
||||
import (
|
||||
"reflect"
|
||||
"strings"
|
||||
"testing"
|
||||
|
||||
"git.novox.be/novox/mesh-sdk/go/seatdef"
|
||||
)
|
||||
|
||||
// The delivery seat answers "what did the mesh's checks say of this pull request?" as a verb of its own,
|
||||
// `checks` (novox/hq ADR 0239): read by repository and a pull request's number or a commit.
|
||||
func TestTheDeliverySeatPromisesChecks(t *testing.T) {
|
||||
seat, ok := SeatNamed(DeliverySeat)
|
||||
if !ok {
|
||||
t.Fatal("the delivery seat is not in the set")
|
||||
}
|
||||
var checks *Verb
|
||||
for i := range seat.Serves {
|
||||
if seat.Serves[i].Name == "checks" {
|
||||
checks = &seat.Serves[i]
|
||||
}
|
||||
}
|
||||
if checks == nil {
|
||||
t.Fatalf("the delivery seat promises %v and not checks", VerbNames(seat.Serves))
|
||||
}
|
||||
props, _ := checks.Input["properties"].(map[string]any)
|
||||
for _, arg := range []string{"repository", "number", "commit"} {
|
||||
if _, has := props[arg]; !has {
|
||||
t.Errorf("checks takes no %q", arg)
|
||||
}
|
||||
}
|
||||
if req, _ := checks.Input["required"].([]string); !reflect.DeepEqual(req, []string{"repository"}) {
|
||||
t.Errorf("checks requires %v, wanted only the repository", req)
|
||||
}
|
||||
|
||||
// Added after the seat's holder shipped, it is optional: the holder serving the ten verbs before it still
|
||||
// holds the seat, and one serving all eleven does too — so the controller and the catalogue can move in
|
||||
// either order, and no check of the catalogue fails on a module nobody touched between the two.
|
||||
if !checks.Optional {
|
||||
t.Fatal("checks is a condition of holding before its holder serves it")
|
||||
}
|
||||
var before []string
|
||||
for _, v := range VerbNames(seat.Serves) {
|
||||
if v != "checks" {
|
||||
before = append(before, v)
|
||||
}
|
||||
}
|
||||
m := Manifest{Module: "mesh-delivery", Claims: []Claim{{Name: DeliverySeat, Scope: ScopeMesh, Serves: before}}}
|
||||
if err := CanHold(m, seat); err != nil {
|
||||
t.Fatalf("a holder without checks yet: %v", err)
|
||||
}
|
||||
m.Claims[0].Serves = VerbNames(seat.Serves)
|
||||
if err := CanHold(m, seat); err != nil {
|
||||
t.Fatalf("a holder serving every verb: %v", err)
|
||||
}
|
||||
// Every other verb is still a condition of holding.
|
||||
m.Claims[0].Serves = append([]string{"checks"}, before[1:]...)
|
||||
if err := CanHold(m, seat); err == nil || !strings.Contains(err.Error(), before[0]) {
|
||||
t.Fatalf("a holder without %s: %v", before[0], err)
|
||||
}
|
||||
}
|
||||
|
||||
// An event whose subject carries parts is said by its subject with `*` for each part, so a consumer naming one
|
||||
// instance or every instance of it is heard as the seat's (design 47 *What each step says*).
|
||||
func TestAnEventWithPartsIsTheSeatsByItsSubject(t *testing.T) {
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
package catalogue
|
||||
|
||||
import (
|
||||
"slices"
|
||||
"testing"
|
||||
)
|
||||
|
||||
// **R298 — a seat's new verb lands in either repository first** (novox/hq issue 298). On 2026-10-07 the
|
||||
// delivery seat gained `checks`: the seat is defined here and held by a module in the catalogue, and
|
||||
// neither could merge first — a controller promising the verb refused the holder that did not serve it
|
||||
// yet, and a holder serving it was refused by the controller that did not promise it. The outcome
|
||||
// asserted: the holder as it was, and the holder serving `checks` too, both hold the delivery seat.
|
||||
//
|
||||
// Written only with what the catalogue package had before the fix (SeatNamed, VerbNames, CanHold), so the
|
||||
// prover can lay it over that commit.
|
||||
func TestReplay298ADeliverySeatHolderHoldsBeforeAndAfterItServesChecks(t *testing.T) {
|
||||
seat, ok := SeatNamed(DeliverySeat)
|
||||
if !ok {
|
||||
t.Fatal("the delivery seat is not in the set")
|
||||
}
|
||||
var before []string
|
||||
for _, v := range VerbNames(seat.Serves) {
|
||||
if v != "checks" {
|
||||
before = append(before, v)
|
||||
}
|
||||
}
|
||||
holder := func(serves []string) Manifest {
|
||||
return Manifest{Module: "mesh-delivery", Claims: []Claim{{Name: DeliverySeat, Scope: ScopeMesh, Serves: serves}}}
|
||||
}
|
||||
if err := CanHold(holder(before), seat); err != nil {
|
||||
t.Fatalf("the holder as the catalogue had it, before it serves checks, is refused: %v", err)
|
||||
}
|
||||
if err := CanHold(holder(append(slices.Clone(before), "checks")), seat); err != nil {
|
||||
t.Fatalf("the holder serving checks is refused — the catalogue cannot merge first: %v", err)
|
||||
}
|
||||
}
|
||||
@@ -1,51 +0,0 @@
|
||||
package catalogue
|
||||
|
||||
import (
|
||||
"strings"
|
||||
"testing"
|
||||
)
|
||||
|
||||
// 1943/AC4: the delivery seat keeps the merge's verbs and no longer offers times, what-if, release, stop or
|
||||
// retire-history: each is a row with no input, optional so the holder of before and the holder of release 6 both hold
|
||||
// the seat, refusing it by name; mark-ready, served by nobody since issue 1022, is gone.
|
||||
func TestTheDeliverySeatHasNoPlanVerbs(t *testing.T) {
|
||||
seat, ok := SeatNamed(DeliverySeat)
|
||||
if !ok {
|
||||
t.Fatal("the delivery seat is not in the set")
|
||||
}
|
||||
rows := map[string]Verb{}
|
||||
for _, v := range seat.Serves {
|
||||
rows[v.Name] = v
|
||||
}
|
||||
for _, name := range []string{"times", "what-if", "release", "stop", "retire-history"} {
|
||||
v, ok := rows[name]
|
||||
replacement := strings.TrimPrefix(v.Description, "Removed in R6 (ADR 0539): refused by name, naming its replacement: ")
|
||||
if !ok || replacement == "" || replacement == v.Description {
|
||||
t.Errorf("%s: in the table %v, replacement %q", name, ok, replacement)
|
||||
continue
|
||||
}
|
||||
if !strings.HasPrefix(v.Description, "Removed in R6 (ADR 0539): refused by name") || !strings.Contains(v.Description, replacement) || !v.Optional {
|
||||
t.Errorf("%s = %q (optional %v), want an optional row refusing it by name", name, v.Description, v.Optional)
|
||||
}
|
||||
if props, _ := v.Input["properties"].(map[string]any); len(props) > 0 {
|
||||
t.Errorf("%s still takes %v", name, props)
|
||||
}
|
||||
}
|
||||
if _, ok := rows["mark-ready"]; ok {
|
||||
t.Errorf("mark-ready is still promised")
|
||||
}
|
||||
for _, kept := range []string{"deliveries", "show", "groups", "checks", "table", "recheck", "close", "stalled", "settle"} {
|
||||
if v, ok := rows[kept]; !ok || strings.HasPrefix(v.Description, "Removed") {
|
||||
t.Errorf("%s is not kept (ADR 0539 clause 17)", kept)
|
||||
}
|
||||
}
|
||||
gate := Manifest{Module: "mesh-delivery", Claims: []Claim{{Name: DeliverySeat, Scope: ScopeMesh,
|
||||
Serves: []string{"deliveries", "show", "groups", "checks", "table", "stalled", "recheck", "close"}}}}
|
||||
if err := CanHold(gate, seat); err != nil {
|
||||
t.Errorf("the gate of release 6 cannot hold the seat: %v", err)
|
||||
}
|
||||
gate.Claims[0].Serves = append(gate.Claims[0].Serves, "times", "what-if", "release", "stop", "retire-history")
|
||||
if err := CanHold(gate, seat); err != nil {
|
||||
t.Errorf("the gate of release 5 cannot hold the seat: %v", err)
|
||||
}
|
||||
}
|
||||
@@ -51,15 +51,15 @@ func TestHoldingAMeshSeatRequiresServingItsVerbs(t *testing.T) {
|
||||
t.Errorf("a holder saying it serves mint: %v", err)
|
||||
}
|
||||
|
||||
// L3: the seat mesh-catalog promises five verbs (the fifth is the seat list, ADR 0636 §4), each optional while two claimants stand (ADR 0604 §1, §6).
|
||||
// The seat mesh-catalog promises the verbs its definition names (milestone 47/G, design 47 G section 307).
|
||||
catalog, ok := SeatNamed(CatalogSeat)
|
||||
if !ok || catalog.Scope != ScopeMesh || catalog.Decision != "novox/hq ADR 0604" || len(catalog.Serves) != 5 {
|
||||
if !ok || catalog.Scope != ScopeMesh || len(catalog.Serves) < 5 {
|
||||
t.Fatalf("mesh-catalog: in the set %v, %+v", ok, catalog)
|
||||
}
|
||||
four := []string{"modules", "module", "provides", "dependents", "seat-definitions"}
|
||||
four := VerbNames(catalog.Serves)
|
||||
for i, v := range catalog.Serves {
|
||||
if v.Name != four[i] || !v.Optional || v.Input == nil {
|
||||
t.Errorf("mesh-catalog's verb %d is %+v, want %s, optional, with its input", i, v, four[i])
|
||||
if v.Input == nil {
|
||||
t.Errorf("mesh-catalog's verb %d is %+v, with no input", i, v)
|
||||
}
|
||||
}
|
||||
// The answers keep the field names of the catalog module's tools they replace (catalog_modules, catalog_module,
|
||||
@@ -87,10 +87,9 @@ func TestHoldingAMeshSeatRequiresServingItsVerbs(t *testing.T) {
|
||||
serves []string
|
||||
word string
|
||||
}{
|
||||
"serving the four": {four, ""},
|
||||
"serving three, optional": {four[:3], ""},
|
||||
"serving none, the old one": {nil, ""},
|
||||
"serving a fifth": {append(slices.Clone(four), "rebuild"), "rebuild"},
|
||||
"serving the four": {four, ""},
|
||||
"serving one short": {four[:len(four)-1], "does not serve " + four[len(four)-1]},
|
||||
"serving a fifth": {append(slices.Clone(four), "rebuild"), "rebuild"},
|
||||
} {
|
||||
err := CanHold(cataloguer(c.serves...), catalog)
|
||||
if (c.word == "") != (err == nil) || (err != nil && !strings.Contains(err.Error(), c.word)) {
|
||||
|
||||
@@ -11,7 +11,9 @@
|
||||
{
|
||||
"name": "list",
|
||||
"description": "Every entry the bus module created, its template, its settings and its fill against its cap.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -41,7 +43,9 @@
|
||||
{
|
||||
"name": "show",
|
||||
"description": "One entry, its template, settings and fill.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Named"
|
||||
},
|
||||
@@ -53,7 +57,9 @@
|
||||
{
|
||||
"name": "check",
|
||||
"description": "Compare what the bus holds with what was asked, entry by entry; a difference that only grows is said as such.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -109,7 +115,9 @@
|
||||
{
|
||||
"name": "orphans",
|
||||
"description": "Entries the bus holds that no manifest asks for; never one whose manifest the judge refused or outgrew, nor one of the foundation's old sections.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {},
|
||||
@@ -135,43 +143,54 @@
|
||||
{
|
||||
"name": "create",
|
||||
"description": "Create one entry now.",
|
||||
"callers": "the bus module's own process only",
|
||||
"callers": [
|
||||
"module:nats"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Entry"
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Held"
|
||||
},
|
||||
"optional": true
|
||||
"optional": true,
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "apply",
|
||||
"description": "Apply a difference that only grows: a larger cap, a longer age.",
|
||||
"callers": "the bus module's own process only",
|
||||
"callers": [
|
||||
"module:nats"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Named"
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Held"
|
||||
},
|
||||
"optional": true
|
||||
"optional": true,
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "recreate",
|
||||
"description": "Rebuild an entry whose settings differ in a way that cannot grow, from its data where the storage type allows, after a stream snapshot.",
|
||||
"callers": "the bus module's process, on the operator's warrant",
|
||||
"callers": [
|
||||
"module:nats"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Warranted"
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Held"
|
||||
},
|
||||
"optional": true
|
||||
"optional": true,
|
||||
"class": "warrant"
|
||||
},
|
||||
{
|
||||
"name": "drop",
|
||||
"description": "Remove one orphan, after a stream snapshot.",
|
||||
"callers": "the bus module's process, on the operator's warrant",
|
||||
"callers": [
|
||||
"module:nats"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Warranted"
|
||||
},
|
||||
@@ -191,7 +210,152 @@
|
||||
"dropped"
|
||||
]
|
||||
},
|
||||
"optional": true
|
||||
"optional": true,
|
||||
"class": "warrant"
|
||||
},
|
||||
{
|
||||
"name": "snapshot-kept",
|
||||
"description": "Take the restore point of one module's kept data on the bus: the data whole and the position of each durable consumer the module reads with, keyed by the module, the kept data, its form and the fingerprint it is taken before (design 47 *A module's kept data on the bus*).",
|
||||
"callers": [
|
||||
"holder:node-backup@same-node"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module",
|
||||
"minLength": 1
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data, its local name in the module's manifest",
|
||||
"minLength": 1
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form, the number the holder raises when it changes how it writes it (0 when undeclared)"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint the restore point is taken before",
|
||||
"minLength": 1
|
||||
},
|
||||
"why": {
|
||||
"type": "string",
|
||||
"description": "why it is taken"
|
||||
},
|
||||
"catch-up": {
|
||||
"type": "object",
|
||||
"description": "the catch-up tool the newer manifest declares beside the kept data and its arguments whole, recorded in the restore point (design 47 G 299, 406)",
|
||||
"properties": {
|
||||
"tool": {
|
||||
"type": "string"
|
||||
},
|
||||
"arguments": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"tool"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint"
|
||||
],
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"point": {
|
||||
"$ref": "#/defs/KeptPoint"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed; set alone"
|
||||
}
|
||||
},
|
||||
"description": "the restore point taken, or the error"
|
||||
},
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "restore-kept",
|
||||
"description": "Restore one module's kept data from its restore point beside the live data, never over it: the live data is set aside under a name of its own and the consumers' positions are set back with it. With aside-only it sets the live data aside and restores nothing; with discard-aside, naming data set aside, it removes that data and restores nothing (design 47 G 405).",
|
||||
"callers": [
|
||||
"holder:node-backup@same-node"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module",
|
||||
"minLength": 1
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data, its local name in the module's manifest",
|
||||
"minLength": 1
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form, the number the holder raises when it changes how it writes it (0 when undeclared)"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint the restore point is taken before",
|
||||
"minLength": 1
|
||||
},
|
||||
"snapshot": {
|
||||
"type": "string",
|
||||
"description": "the restore point's name; not with aside-only or discard-aside",
|
||||
"minLength": 1
|
||||
},
|
||||
"why": {
|
||||
"type": "string",
|
||||
"description": "why"
|
||||
},
|
||||
"aside-only": {
|
||||
"type": "boolean",
|
||||
"description": "set the live data aside and restore nothing"
|
||||
},
|
||||
"discard-aside": {
|
||||
"type": "string",
|
||||
"description": "the name of data set aside: remove it and restore nothing"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint"
|
||||
],
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"restored": {
|
||||
"type": "boolean",
|
||||
"description": "the restore point is the live data now"
|
||||
},
|
||||
"aside": {
|
||||
"$ref": "#/defs/Aside"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed; set alone"
|
||||
}
|
||||
},
|
||||
"description": "what was restored and what was set aside, or the error"
|
||||
},
|
||||
"class": "act"
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
@@ -558,6 +722,10 @@
|
||||
"type": "string"
|
||||
},
|
||||
"description": "its subjects, for a stream"
|
||||
},
|
||||
"objects": {
|
||||
"type": "string",
|
||||
"description": "the bus name of the state's <state>-objects, where its large values go (design 47 G 58, 399)"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -565,6 +733,133 @@
|
||||
"storage-type"
|
||||
],
|
||||
"description": "the binding a module receives in its membership for one entry (ADR 0595 §1, §7)"
|
||||
},
|
||||
"KeptPoint": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module",
|
||||
"minLength": 1
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data, its local name in the module's manifest",
|
||||
"minLength": 1
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form, the number the holder raises when it changes how it writes it (0 when undeclared)"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint the restore point is taken before",
|
||||
"minLength": 1
|
||||
},
|
||||
"snapshot": {
|
||||
"type": "string",
|
||||
"description": "the restore point's name"
|
||||
},
|
||||
"consumers": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"stream": {
|
||||
"type": "string",
|
||||
"description": "the stream"
|
||||
},
|
||||
"consumer": {
|
||||
"type": "string",
|
||||
"description": "the durable consumer"
|
||||
},
|
||||
"sequence": {
|
||||
"type": "integer",
|
||||
"description": "its acknowledged position"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"stream",
|
||||
"consumer",
|
||||
"sequence"
|
||||
]
|
||||
},
|
||||
"description": "each durable consumer the module reads with, and its position"
|
||||
},
|
||||
"size": {
|
||||
"type": "integer",
|
||||
"description": "its size in bytes"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when it was taken",
|
||||
"format": "date-time"
|
||||
},
|
||||
"catch-up": {
|
||||
"type": "object",
|
||||
"description": "the catch-up tool and its arguments the restore point records (design 47 G 406)",
|
||||
"properties": {
|
||||
"tool": {
|
||||
"type": "string"
|
||||
},
|
||||
"arguments": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"tool"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint",
|
||||
"snapshot"
|
||||
],
|
||||
"description": "a restore point of one module's kept data on the bus, whole, with its consumers' positions"
|
||||
},
|
||||
"Aside": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "its id, for discard-aside"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "the form it held"
|
||||
},
|
||||
"name": {
|
||||
"type": "string",
|
||||
"description": "the name it is kept under on the bus"
|
||||
},
|
||||
"size": {
|
||||
"type": "integer",
|
||||
"description": "its size in bytes"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when it was set aside",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"module",
|
||||
"kept",
|
||||
"name"
|
||||
],
|
||||
"description": "live kept data a restore set aside, never removed but by discard-aside"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -84,15 +84,26 @@
|
||||
},
|
||||
{
|
||||
"name": "resync",
|
||||
"description": "Read every observer's findings again and raise and clear what differs from the open conditions: the recovery of a keeper that missed a change.",
|
||||
"description": "Ask the observers to state their findings again, every one or the one named, and raise and clear what differs from the open conditions: the recovery of a keeper that missed a change. Each call is written in the hand-act log of the seat mesh-hand-acts (design 47 G 390).",
|
||||
"input": {
|
||||
"properties": {},
|
||||
"type": "object"
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "ask this observer alone; none asks all"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what was raised and cleared again"
|
||||
}
|
||||
},
|
||||
"callers": [
|
||||
"operator",
|
||||
"healers",
|
||||
"sessions"
|
||||
]
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
@@ -113,6 +124,40 @@
|
||||
"body": {
|
||||
"$ref": "#/defs/ConditionEvent"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "findings-asked",
|
||||
"keep": {
|
||||
"max-age-days": 7,
|
||||
"max-mib": 16
|
||||
},
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "the keeper asks every observer, or one, to state its findings (design 47 G 384, 390)",
|
||||
"properties": {
|
||||
"ask": {
|
||||
"type": "string",
|
||||
"description": "the ask's id"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"by": {
|
||||
"type": "string",
|
||||
"description": "who asked: the keeper, or the person or session that called resync"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "to ask one observer; none asks all"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"ask",
|
||||
"at",
|
||||
"by"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"family": {
|
||||
@@ -363,6 +408,14 @@
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"owner": {
|
||||
"type": "string",
|
||||
"description": "the module the finding is about, when not the observer"
|
||||
},
|
||||
"waiting-on": {
|
||||
"type": "string",
|
||||
"description": "what it waits on: a person, a part or a call"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -380,7 +433,67 @@
|
||||
"description": "one finding of the observer that wrote it"
|
||||
}
|
||||
],
|
||||
"description": "every observer's findings, one key per finding; a key written raises or changes the condition of the same key, a key deleted clears it"
|
||||
"description": "every observer's findings, one key per finding, kept in the observer's own state and read only by its owner's read tool; the keeper hears each change as the observer's events finding-written, finding-cleared and findings-stated (design 47 G 383, 434)"
|
||||
},
|
||||
{
|
||||
"name": "findings-views",
|
||||
"template": "state",
|
||||
"description": "the keeper's sources: one key per observer and node, its last stated set with its at, its pending keys and the open asks; deleted when the module leaves the catalog or the node (design 47 G 388)",
|
||||
"key-forms": [
|
||||
{
|
||||
"key": "<observer>.<node>",
|
||||
"description": "one observer on one node",
|
||||
"value": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer"
|
||||
},
|
||||
"observer": {
|
||||
"type": "string"
|
||||
},
|
||||
"node": {
|
||||
"type": "string"
|
||||
},
|
||||
"stated": {
|
||||
"type": "object",
|
||||
"description": "the last findings-stated set",
|
||||
"properties": {
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"findings": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/bodies/Finding"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"pending": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "the keys it cannot judge yet"
|
||||
},
|
||||
"asks": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "the open asks"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"observer",
|
||||
"node"
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"defs": {
|
||||
@@ -643,5 +756,191 @@
|
||||
"change"
|
||||
]
|
||||
}
|
||||
},
|
||||
"bodies": {
|
||||
"Finding": {
|
||||
"type": "object",
|
||||
"description": "one finding as an observer says it: the layout whole, plus scope, id and since (design 47 G 437, 439)",
|
||||
"properties": {
|
||||
"kind": {
|
||||
"type": "string"
|
||||
},
|
||||
"scope": {
|
||||
"type": "string",
|
||||
"description": "the key's first part: <scope>.<id>.<kind> (ADR 0564)"
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the key's second part"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"since": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "since when the finding stands"
|
||||
},
|
||||
"severity": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"urgent",
|
||||
"warning"
|
||||
]
|
||||
},
|
||||
"summary": {
|
||||
"type": "string",
|
||||
"description": "one line"
|
||||
},
|
||||
"headline": {
|
||||
"type": "string"
|
||||
},
|
||||
"explanation": {
|
||||
"type": "string"
|
||||
},
|
||||
"subject": {
|
||||
"$ref": "#/defs/Subject"
|
||||
},
|
||||
"evidence": {
|
||||
"type": "array",
|
||||
"description": "newest first, at most 10",
|
||||
"items": {
|
||||
"$ref": "#/defs/Evidence"
|
||||
}
|
||||
},
|
||||
"source": {
|
||||
"type": "string",
|
||||
"description": "the row, probe or event that saw it"
|
||||
},
|
||||
"observer": {
|
||||
"type": "string",
|
||||
"description": "the module that wrote it"
|
||||
},
|
||||
"owner": {
|
||||
"type": "string",
|
||||
"description": "the module the finding is about, when not the observer"
|
||||
},
|
||||
"waiting-on": {
|
||||
"type": "string",
|
||||
"description": "what it waits on: a person, a part or a call"
|
||||
},
|
||||
"actions": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/Action"
|
||||
}
|
||||
},
|
||||
"needs": {
|
||||
"type": "string"
|
||||
},
|
||||
"resolver": {
|
||||
"type": "string",
|
||||
"description": "self, operator, agent or healer:<name>"
|
||||
},
|
||||
"ref": {
|
||||
"type": "string",
|
||||
"description": "the key's last part when it is not the kind"
|
||||
},
|
||||
"run": {
|
||||
"type": "string",
|
||||
"description": "what of its own saw it last"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"kind",
|
||||
"scope",
|
||||
"id",
|
||||
"at",
|
||||
"since",
|
||||
"severity",
|
||||
"summary",
|
||||
"subject",
|
||||
"source",
|
||||
"observer"
|
||||
]
|
||||
},
|
||||
"FindingWritten": {
|
||||
"$ref": "#/bodies/Finding"
|
||||
},
|
||||
"FindingCleared": {
|
||||
"type": "object",
|
||||
"description": "an observer no longer observes a finding",
|
||||
"properties": {
|
||||
"kind": {
|
||||
"type": "string"
|
||||
},
|
||||
"scope": {
|
||||
"type": "string"
|
||||
},
|
||||
"id": {
|
||||
"type": "string"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"why": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"kind",
|
||||
"scope",
|
||||
"id",
|
||||
"at",
|
||||
"why"
|
||||
]
|
||||
},
|
||||
"FindingsStated": {
|
||||
"type": "object",
|
||||
"description": "every finding an observer observes now, at its start and when asked (design 47 G 384, 439)",
|
||||
"properties": {
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"asked": {
|
||||
"type": "string",
|
||||
"description": "the ask it answers; none at a start"
|
||||
},
|
||||
"findings": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/bodies/Finding"
|
||||
}
|
||||
},
|
||||
"pending": {
|
||||
"type": "array",
|
||||
"description": "the keys the observer cannot judge yet since its start, with their since and bound",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"key": {
|
||||
"type": "string"
|
||||
},
|
||||
"since": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"bound": {
|
||||
"type": "string",
|
||||
"description": "a duration such as 5m"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"key",
|
||||
"since",
|
||||
"bound"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"at",
|
||||
"findings",
|
||||
"pending"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -64,7 +64,9 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"callers": "any caller whose role grants it; the checker asks it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
||||
@@ -176,7 +176,79 @@
|
||||
}
|
||||
}
|
||||
],
|
||||
"description": "The merge check's tries: start one, read one, end one. The checker's own events stay under its own subjects (ADR 0620 §2).",
|
||||
"description": "The merge check's tries: start one, read one, end one. The seat says each check's end as checked and what the checker owes the forge as owed; the checker's other events stay under its own subjects (ADR 0620 \u00a72).",
|
||||
"family": {
|
||||
"name": "mesh-delivery-checker.events",
|
||||
"max-age-days": 7
|
||||
},
|
||||
"events": [
|
||||
{
|
||||
"name": "checked",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a candidate checked: its entries judged at the group's heads (design 47 *What each step says*)",
|
||||
"properties": {
|
||||
"group": {
|
||||
"type": "string",
|
||||
"description": "the group, its branch"
|
||||
},
|
||||
"heads": {
|
||||
"type": "string",
|
||||
"description": "the heads checked, 12 hex digits, as the candidate's revisions are keyed"
|
||||
},
|
||||
"source": {
|
||||
"type": "integer",
|
||||
"description": "the source revision the heads are merged onto"
|
||||
},
|
||||
"catalog": {
|
||||
"type": "integer",
|
||||
"description": "the candidate's catalog graph revision judged, by its number on the seat mesh-catalog"
|
||||
},
|
||||
"verdict": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"pass",
|
||||
"fail",
|
||||
"could not run"
|
||||
],
|
||||
"description": "pass, fail, or could not run when a part the check needs did not answer"
|
||||
},
|
||||
"words": {
|
||||
"type": "string",
|
||||
"description": "what failed first, or the part not heard"
|
||||
},
|
||||
"entries": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/CheckedEntry"
|
||||
},
|
||||
"description": "the entries checked"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"group",
|
||||
"heads",
|
||||
"verdict"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "owed",
|
||||
"subject": "owed.<repository>.<number>",
|
||||
"body": {
|
||||
"$ref": "#/defs/Owed"
|
||||
},
|
||||
"keep": {
|
||||
"max-age-days": 7,
|
||||
"max-mib": 64
|
||||
}
|
||||
}
|
||||
],
|
||||
"holder-events": [
|
||||
{
|
||||
"name": "verdict",
|
||||
@@ -746,5 +818,90 @@
|
||||
"description": "the previews of a head merged onto a trunk",
|
||||
"history": 5
|
||||
}
|
||||
]
|
||||
],
|
||||
"defs": {
|
||||
"Owed": {
|
||||
"type": "object",
|
||||
"description": "the status the checker owes the forge for a head, said under its id and safe to repeat (a status replaces what stands); the forge bridge performs it through the seat git's verb status (design 47 *What the gate owes the forge*)",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the act's id, the same each time it is said again"
|
||||
},
|
||||
"act": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"status"
|
||||
],
|
||||
"description": "the act: always status"
|
||||
},
|
||||
"repository": {
|
||||
"type": "string",
|
||||
"description": "the repository, <owner>/<name>",
|
||||
"minLength": 1
|
||||
},
|
||||
"number": {
|
||||
"type": "integer",
|
||||
"description": "the pull request's number"
|
||||
},
|
||||
"head": {
|
||||
"type": "string",
|
||||
"description": "the pull request's head the status is on",
|
||||
"pattern": "^[0-9a-f]{40}$"
|
||||
},
|
||||
"context": {
|
||||
"type": "string",
|
||||
"description": "its context, mesh/check"
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "pending, success, failure or error"
|
||||
},
|
||||
"description": {
|
||||
"type": "string",
|
||||
"description": "what it says"
|
||||
},
|
||||
"target": {
|
||||
"type": "string",
|
||||
"description": "the page it links to"
|
||||
},
|
||||
"said": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when the checker first said it"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"act",
|
||||
"repository",
|
||||
"number",
|
||||
"head",
|
||||
"context",
|
||||
"state"
|
||||
]
|
||||
},
|
||||
"CheckedEntry": {
|
||||
"type": "object",
|
||||
"description": "one entry of the candidate checked: a module at its fingerprint",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"fp": {
|
||||
"type": "string",
|
||||
"description": "the entry's fingerprint"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node it was composed for, when the check composed it on one"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"fp"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -159,6 +159,86 @@
|
||||
}
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
{
|
||||
"name": "machine-away",
|
||||
"subject": "machine-away.<machine>",
|
||||
"keep": {
|
||||
"max-age-days": 90,
|
||||
"max-mib": 16
|
||||
},
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "the watchman's presence key of a machine expired (ADR 0564 4); published by the holder of this seat alone for another machine (design 47 G 436)",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"machine": {
|
||||
"type": "string",
|
||||
"description": "the machine whose presence changed"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"last-heard": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when the machine was last heard"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"machine",
|
||||
"at",
|
||||
"last-heard"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "machine-back",
|
||||
"subject": "machine-back.<machine>",
|
||||
"keep": {
|
||||
"max-age-days": 90,
|
||||
"max-mib": 16
|
||||
},
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a machine is heard again after it was away",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"machine": {
|
||||
"type": "string",
|
||||
"description": "the machine whose presence changed"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"last-heard": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when the machine was last heard"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"machine",
|
||||
"at",
|
||||
"last-heard"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"family": {
|
||||
"name": "mesh-watchdogs.events",
|
||||
"max-age-days": 7
|
||||
},
|
||||
"states": [
|
||||
{
|
||||
"name": "presence",
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
"verbs": [
|
||||
{
|
||||
"name": "backed-up",
|
||||
"description": "What this machine backs up: each module, what it declared, its last good night, how many restore points are kept and the repository's size.",
|
||||
"description": "What this machine backs up: each module, what it declared, its last good night, how many restore points are kept and the repository's size. Also each module's restore points of its kept data on the bus (the kept data, the form, the fingerprint each was taken before) and the data set aside at each restore, with its size.",
|
||||
"replaces": [
|
||||
"restic snapshots"
|
||||
],
|
||||
@@ -24,7 +24,7 @@
|
||||
},
|
||||
{
|
||||
"name": "now",
|
||||
"description": "Take a backup now, of one module or of every module on this machine — before a migration, a retirement or anything else that could go wrong.",
|
||||
"description": "Take a backup now, of one module or of every module on this machine — before a migration, a retirement or anything else that could go wrong. With kept, a restore point of one kept data on the bus instead, said by the event ended.",
|
||||
"replaces": [
|
||||
"restic backup"
|
||||
],
|
||||
@@ -33,14 +33,42 @@
|
||||
"module": {
|
||||
"description": "one module (optional)",
|
||||
"type": "string"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "one kept data of the module on the bus, its local name: its restore point is taken by the bus module's account, of the node holding mesh-broker"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "with kept: its form now"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "with kept: the fingerprint the restore point is taken before"
|
||||
},
|
||||
"catch-up": {
|
||||
"type": "object",
|
||||
"description": "with kept: the catch-up tool the newer manifest declares beside it and its arguments whole, recorded in the restore point (design 47 G 299, 406)",
|
||||
"properties": {
|
||||
"tool": {
|
||||
"type": "string"
|
||||
},
|
||||
"arguments": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"tool"
|
||||
]
|
||||
}
|
||||
},
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "restore",
|
||||
"description": "Restore one module's data from a restore point BESIDE the live data, never over it: each directory as \u003cpath\u003e.restored-\u003cdate\u003e. Swapping it in is a person's act. Lists the restore points when none is named.",
|
||||
"description": "Restore one module's data from a restore point BESIDE the live data, never over it: each directory as <path>.restored-<date>. Swapping it in is a person's act. Lists the restore points when none is named. With kept, the restore point of one kept data on the bus by its module, kept data and form, the live data set aside and never removed, said by the event restored.",
|
||||
"replaces": [
|
||||
"restic restore"
|
||||
],
|
||||
@@ -57,13 +85,96 @@
|
||||
"snapshot": {
|
||||
"description": "the restore point (from `backed-up`; the newest when omitted)",
|
||||
"type": "string"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "one kept data of the module on the bus, its local name: its restore point is taken by the bus module's account, of the node holding mesh-broker"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "with kept: its form now"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "with kept: the fingerprint the restore point is taken before"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module"
|
||||
],
|
||||
"type": "object"
|
||||
},
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "aside",
|
||||
"description": "Set one module's live kept data on the bus aside under a name of its own and restore nothing, after the node agent stopped the newer build (design 47 G 297, 405); the data set aside is listed by backed-up and removed only by discard-aside.",
|
||||
"class": "act",
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "one kept data of the module on the bus, its local name: its restore point is taken by the bus module's account, of the node holding mesh-broker"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "with kept: its form now"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "with kept: the fingerprint the restore point is taken before"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint"
|
||||
]
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"aside": {
|
||||
"type": "string",
|
||||
"description": "the name the live data is set aside under"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed; set alone"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "discard-aside",
|
||||
"description": "Remove data a restore set aside, on a person's call alone; writes the act, who and why in the hand-act log of the seat mesh-hand-acts.",
|
||||
"callers": [
|
||||
"operator"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the aside's id, as backed-up lists it"
|
||||
},
|
||||
"why": {
|
||||
"type": "string",
|
||||
"description": "why"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"why"
|
||||
]
|
||||
},
|
||||
"class": "act"
|
||||
}
|
||||
],
|
||||
"receives": [
|
||||
@@ -77,5 +188,103 @@
|
||||
"comment": "#",
|
||||
"dirs": true
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
{
|
||||
"name": "ended",
|
||||
"subject": "ended.<node>.<module>.<kept>",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a restore point of a kept data on the bus taken, done or failed",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint"
|
||||
},
|
||||
"outcome": {
|
||||
"enum": [
|
||||
"done",
|
||||
"failed"
|
||||
]
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint",
|
||||
"outcome"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "restored",
|
||||
"subject": "restored.<node>.<module>.<kept>",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a kept data on the bus restored from its restore point beside the live data, done or failed",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint"
|
||||
},
|
||||
"outcome": {
|
||||
"enum": [
|
||||
"done",
|
||||
"failed"
|
||||
]
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint",
|
||||
"outcome"
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -5,8 +5,14 @@
|
||||
"grain": "whole",
|
||||
"domain": "Core",
|
||||
"decision": "novox/hq ADR 0563",
|
||||
"description": "The node seat every node's engine holds (novox/hq ADR 0563, ADR 0618 §3, §4): its hand acts on the operator's warrant, its read-only judgements, its compositions and what it reads of a manifest. Each verb is answered on this node's subject, mesh.seat.node-engine.tool.<verb>.<node>, and each event is published on mesh.seat.node-engine.event.<event>.<node>, the node's name its last token.",
|
||||
"description": "The node seat every node's engine holds (novox/hq ADR 0563, ADR 0618 §3, §4): its hand acts on the operator's warrant, its read-only judgements, its compositions and what it reads of a manifest. Each verb is answered on this node's subject, mesh.seat.node-engine.tool.<verb>.<node>, and each event is published on mesh.seat.node-engine.event.<event>.<node>, the node's name its last token, or, for an event whose subject names <node>, there (composed.<node>, running.<node>.<module>): the grants part grants a node's account only its own node's subjects (ADR 0363 §2).",
|
||||
"held-by-the-engine": true,
|
||||
"acts": [
|
||||
{
|
||||
"step": "compose",
|
||||
"on": "every"
|
||||
}
|
||||
],
|
||||
"verbs": [
|
||||
{
|
||||
"name": "hand-over",
|
||||
@@ -29,7 +35,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Asked"
|
||||
}
|
||||
},
|
||||
"class": "warrant"
|
||||
},
|
||||
{
|
||||
"name": "access-act",
|
||||
@@ -57,7 +64,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Asked"
|
||||
}
|
||||
},
|
||||
"class": "warrant"
|
||||
},
|
||||
{
|
||||
"name": "judge-directories",
|
||||
@@ -68,7 +76,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Said"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "setuid-search",
|
||||
@@ -84,7 +93,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Said"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "root-free",
|
||||
@@ -107,7 +117,8 @@
|
||||
"required": [
|
||||
"machines"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "acts",
|
||||
@@ -127,7 +138,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Acts"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "packages",
|
||||
@@ -217,7 +229,8 @@
|
||||
"node",
|
||||
"source"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "composition",
|
||||
@@ -491,7 +504,8 @@
|
||||
"composition",
|
||||
"judged"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "compose",
|
||||
@@ -554,7 +568,8 @@
|
||||
"required": [
|
||||
"pass"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "compose-candidate",
|
||||
@@ -633,7 +648,8 @@
|
||||
"own",
|
||||
"took"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "manifest-reads",
|
||||
@@ -673,12 +689,17 @@
|
||||
"stated-at"
|
||||
],
|
||||
"description": "what this machine's engine reads of a manifest (ADR 0618 §3)"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "seat-list",
|
||||
"description": "The seat list this engine holds and what it waits for (novox/hq ADR 0636 §7): each seat's source (trunk or bootstrap) and digest, the seats held from the bootstrap alone, the definitions refused, the last error and whether the seat mesh-catalog has answered. Read-only.",
|
||||
"callers": "the operator and the healers",
|
||||
"callers": [
|
||||
"persons",
|
||||
"sessions",
|
||||
"healers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {}
|
||||
@@ -690,7 +711,11 @@
|
||||
{
|
||||
"name": "seat-list-again",
|
||||
"description": "Make this engine read the seat list from the seat mesh-catalog now (novox/hq ADR 0636 §7), the recovery of a list unread; it answers what it holds afterwards, and the error when the read failed. A read that changed nothing still ends the engine's wait.",
|
||||
"callers": "the operator and the healers",
|
||||
"callers": [
|
||||
"persons",
|
||||
"sessions",
|
||||
"healers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {}
|
||||
@@ -698,6 +723,29 @@
|
||||
"answer": {
|
||||
"$ref": "#/defs/SeatList"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "process-builds",
|
||||
"description": "The build each process on this node was started with (design 47 *The revision view*): per service and container the fingerprint the node-engine handed it in MESH_FINGERPRINT, or why it is unknown, and when it started. Narrowed by module. Reads only.",
|
||||
"callers": [
|
||||
"persons",
|
||||
"sessions",
|
||||
"healers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "only this module's processes"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/ProcessBuilds"
|
||||
},
|
||||
"class": "read"
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
@@ -728,6 +776,31 @@
|
||||
"body": {
|
||||
"$ref": "#/defs/ManifestReadsChanged"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "composed",
|
||||
"subject": "composed.<node>",
|
||||
"body": {
|
||||
"$ref": "#/defs/Composed"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "running",
|
||||
"subject": "running.<node>.<module>",
|
||||
"keep": {
|
||||
"max-age-days": 0,
|
||||
"last-per-subject": true
|
||||
},
|
||||
"body": {
|
||||
"$ref": "#/defs/Running"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "capabilities-changed",
|
||||
"subject": "capabilities-changed.<node>",
|
||||
"body": {
|
||||
"$ref": "#/defs/CapabilitiesChanged"
|
||||
}
|
||||
}
|
||||
],
|
||||
"family": {
|
||||
@@ -2658,6 +2731,183 @@
|
||||
"state",
|
||||
"since"
|
||||
]
|
||||
},
|
||||
"Composed": {
|
||||
"type": "object",
|
||||
"description": "an entry composed on a node (design 47 *What each step says*)",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint of the want composed"
|
||||
},
|
||||
"digest": {
|
||||
"type": "string",
|
||||
"description": "the digest of the composition (design 47 G 404)"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when, RFC 3339",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"node",
|
||||
"module",
|
||||
"fingerprint",
|
||||
"digest",
|
||||
"at"
|
||||
]
|
||||
},
|
||||
"Running": {
|
||||
"type": "object",
|
||||
"description": "a module running healthy on a node at a build: what the node-engines of other nodes and the grants part decide a seat's pass from (ADR 0660 §2), kept last per subject with no age limit",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint of the build it runs; none with stopped"
|
||||
},
|
||||
"manifest": {
|
||||
"type": "string",
|
||||
"description": "the digest of that build's manifest, the indexer's manifest of it, read by digest from the catalog half"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when it was seen running healthy, RFC 3339",
|
||||
"format": "date-time"
|
||||
},
|
||||
"stopped": {
|
||||
"type": "boolean",
|
||||
"description": "true when the module no longer runs on the node: no fingerprint or manifest then (design 47 G 365, 404); mesh-sdk's SeatsToPassOn counts such a module as not running there"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"node",
|
||||
"module",
|
||||
"at"
|
||||
]
|
||||
},
|
||||
"CapabilitiesChanged": {
|
||||
"type": "object",
|
||||
"description": "a node's capabilities changed, which the assigner places by",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node"
|
||||
},
|
||||
"capabilities": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "its capabilities now"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when, RFC 3339",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"node",
|
||||
"capabilities",
|
||||
"at"
|
||||
]
|
||||
},
|
||||
"ProcessBuild": {
|
||||
"type": "object",
|
||||
"description": "the build one process of a module was started with",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"process": {
|
||||
"type": "string",
|
||||
"description": "the service's unit or the container's name"
|
||||
},
|
||||
"kind": {
|
||||
"type": "string",
|
||||
"description": "service or container",
|
||||
"enum": [
|
||||
"service",
|
||||
"container"
|
||||
]
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint handed to it in MESH_FINGERPRINT; empty when it was started without one"
|
||||
},
|
||||
"unknown": {
|
||||
"type": "string",
|
||||
"description": "why its build is unknown: started before the node-engine handed MESH_FINGERPRINT, or the value could not be read"
|
||||
},
|
||||
"started": {
|
||||
"type": "string",
|
||||
"description": "when it was started, RFC 3339",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"process",
|
||||
"kind"
|
||||
]
|
||||
},
|
||||
"ProcessBuilds": {
|
||||
"type": "object",
|
||||
"description": "what process-builds answers",
|
||||
"properties": {
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node"
|
||||
},
|
||||
"processes": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/ProcessBuild"
|
||||
},
|
||||
"description": "every process the node-engine started, by module"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why they could not be read"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"node",
|
||||
"processes"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -126,7 +126,7 @@
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "open (open and held), ended or all; none is open when no key or since is given, else all"
|
||||
"description": "open (open, held and held-back), ended or all; none is open when no key or since is given, else all"
|
||||
},
|
||||
"since": {
|
||||
"type": "string",
|
||||
@@ -154,7 +154,11 @@
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "how the ask stands: open, held, or how it ended (answered, expired, cancelled)"
|
||||
"description": "how the ask stands: open, held (no ready channel), held-back (kept open behind the asker's newer asks, ADR 0666 §12), or how it ended (answered, expired, cancelled)"
|
||||
},
|
||||
"held-since": {
|
||||
"type": "string",
|
||||
"description": "when the ask was held back, RFC 3339; present while its state is held-back"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -176,6 +180,41 @@
|
||||
"asks"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ask-again",
|
||||
"description": "Offer a held-back ask now, on a channel that is ready: the asker's ask kept open behind its newer asks (design 47 G 83, 394).",
|
||||
"class": "act",
|
||||
"callers": [
|
||||
"operator",
|
||||
"healers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"key": {
|
||||
"type": "string",
|
||||
"description": "<asker>.<id> of the held-back ask"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"key"
|
||||
],
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "where the ask stands after it was offered",
|
||||
"properties": {
|
||||
"state": {
|
||||
"type": "string"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it was not offered; set alone"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"accepts": [
|
||||
@@ -248,7 +287,7 @@
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "how it stands: open, chosen, expired, cancelled, replaced or refused"
|
||||
"description": "how it stands: open, held-back (kept open behind the asker's newer asks, ADR 0666 §12), chosen, expired, cancelled, replaced or refused"
|
||||
},
|
||||
"opened": {
|
||||
"type": "string",
|
||||
@@ -269,6 +308,10 @@
|
||||
"type": "boolean",
|
||||
"description": "its asker has been told how it ended"
|
||||
},
|
||||
"held-since": {
|
||||
"type": "string",
|
||||
"description": "when the ask was held back, RFC 3339; present while its state is held-back"
|
||||
},
|
||||
"answer": {
|
||||
"type": "string",
|
||||
"description": "how it ended, in words"
|
||||
|
||||
@@ -13,7 +13,9 @@
|
||||
{
|
||||
"name": "mirror",
|
||||
"description": "Copy an outside image into the store by its pinned digest; emits published or refused.",
|
||||
"callers": "mesh-build-image's holder of the image build seat",
|
||||
"callers": [
|
||||
"seat:node-build-image"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -58,7 +60,9 @@
|
||||
{
|
||||
"name": "tags",
|
||||
"description": "The tags of one image and the digest each names.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -109,8 +113,10 @@
|
||||
},
|
||||
{
|
||||
"name": "hold",
|
||||
"description": "Keep one untagged bundle, archive or copied base from removal by retention, as the artifact sweep's rules keep it (ADR 0617 §2); never an image of the holder's own. Emits held.",
|
||||
"callers": "the module that runs the artifact sweep alone",
|
||||
"description": "Keep one untagged bundle, archive or copied base from removal by retention, as the artifact sweep's rules keep it (ADR 0617 \u00a72); never an image of the holder's own. Emits held.",
|
||||
"callers": [
|
||||
"seat:mesh-artifact-sweep"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -154,7 +160,9 @@
|
||||
{
|
||||
"name": "release",
|
||||
"description": "Let a hold go; emits released. A release of what is not held answers released false and emits nothing, never an error: the outcome asked holds already. By hand only through the holder's own tool, the operator's session as the proved caller, recorded as a hand act.",
|
||||
"callers": "the module that runs the artifact sweep; the operator's session through the holder's tool",
|
||||
"callers": [
|
||||
"seat:mesh-artifact-sweep"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -193,8 +201,10 @@
|
||||
},
|
||||
{
|
||||
"name": "list",
|
||||
"description": "What the store holds of one repository, or of every repository the seat holds when none is named: every image manifest and index, each with its digest, whether it is an index (and the manifests an index names), the tags naming it, its size and whether it is held. Read from the store itself, so a manifest no tag names is listed too; it reads only (ADR 0632 §3).",
|
||||
"callers": "any caller whose role grants it",
|
||||
"description": "What the store holds of one repository, or of every repository the seat holds when none is named: every image manifest and index, each with its digest, whether it is an index (and the manifests an index names), the tags naming it, its size and whether it is held. Read from the store itself, so a manifest no tag names is listed too; it reads only (ADR 0632 \u00a73).",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -2,7 +2,7 @@
|
||||
"format": 1,
|
||||
"seat": "mesh-artifact-sweep",
|
||||
"scope": "mesh",
|
||||
"grain": "seat-list",
|
||||
"grain": "whole",
|
||||
"domain": "Delivery",
|
||||
"decision": "novox/hq ADR 0571",
|
||||
"verbs": [
|
||||
@@ -25,6 +25,10 @@
|
||||
}
|
||||
},
|
||||
"type": "object"
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what artifacts answers, as its description says"
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -44,6 +48,41 @@
|
||||
"references"
|
||||
],
|
||||
"type": "object"
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"store": {
|
||||
"type": "string",
|
||||
"description": "the store asked, host and port"
|
||||
},
|
||||
"held": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "the references the store holds"
|
||||
},
|
||||
"gone": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "the references the store answered 404 for"
|
||||
},
|
||||
"unknown": {
|
||||
"type": "object",
|
||||
"additionalProperties": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "a reference the store could not be asked about, to why"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"held",
|
||||
"gone"
|
||||
],
|
||||
"description": "what held answers: a reference is in held, gone or unknown, never none of them"
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -69,6 +108,10 @@
|
||||
}
|
||||
},
|
||||
"type": "object"
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what collect answers, as its description says"
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -77,6 +120,10 @@
|
||||
"input": {
|
||||
"properties": {},
|
||||
"type": "object"
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what mirrors answers, as its description says"
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -93,12 +140,65 @@
|
||||
"node"
|
||||
],
|
||||
"type": "object"
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what images answers, as its description says"
|
||||
}
|
||||
}
|
||||
],
|
||||
"family": {
|
||||
"name": "mesh-artifact-sweep.events",
|
||||
"max-age-days": 7
|
||||
},
|
||||
"events": [
|
||||
{
|
||||
"name": "artifacts-gone"
|
||||
"name": "artifacts-gone",
|
||||
"body": {
|
||||
"$ref": "#/defs/ArtifactsGone"
|
||||
}
|
||||
}
|
||||
]
|
||||
],
|
||||
"defs": {
|
||||
"ArtifactsGone": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"event": {
|
||||
"type": "string",
|
||||
"description": "artifacts-gone"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module whose builder's key names a gone artifact"
|
||||
},
|
||||
"key": {
|
||||
"type": "string",
|
||||
"description": "the builder's done key"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the key's fingerprint"
|
||||
},
|
||||
"gone": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "every reference of the key the store does not hold, sorted"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when the sweep found it"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"event",
|
||||
"module",
|
||||
"fingerprint",
|
||||
"gone"
|
||||
],
|
||||
"description": "the body of artifacts-gone"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,7 +11,9 @@
|
||||
{
|
||||
"name": "list",
|
||||
"description": "Every entry the bus module created, its template, its settings and its fill against its cap.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -41,7 +43,9 @@
|
||||
{
|
||||
"name": "show",
|
||||
"description": "One entry, its template, settings and fill.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Named"
|
||||
},
|
||||
@@ -53,7 +57,9 @@
|
||||
{
|
||||
"name": "check",
|
||||
"description": "Compare what the bus holds with what was asked, entry by entry; a difference that only grows is said as such.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -109,7 +115,9 @@
|
||||
{
|
||||
"name": "orphans",
|
||||
"description": "Entries the bus holds that no manifest asks for; never one whose manifest the judge refused or outgrew, nor one of the foundation's old sections.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {},
|
||||
@@ -135,43 +143,54 @@
|
||||
{
|
||||
"name": "create",
|
||||
"description": "Create one entry now.",
|
||||
"callers": "the bus module's own process only",
|
||||
"callers": [
|
||||
"module:nats"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Entry"
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Held"
|
||||
},
|
||||
"optional": true
|
||||
"optional": true,
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "apply",
|
||||
"description": "Apply a difference that only grows: a larger cap, a longer age.",
|
||||
"callers": "the bus module's own process only",
|
||||
"callers": [
|
||||
"module:nats"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Named"
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Held"
|
||||
},
|
||||
"optional": true
|
||||
"optional": true,
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "recreate",
|
||||
"description": "Rebuild an entry whose settings differ in a way that cannot grow, from its data where the storage type allows, after a stream snapshot.",
|
||||
"callers": "the bus module's process, on the operator's warrant",
|
||||
"callers": [
|
||||
"module:nats"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Warranted"
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Held"
|
||||
},
|
||||
"optional": true
|
||||
"optional": true,
|
||||
"class": "warrant"
|
||||
},
|
||||
{
|
||||
"name": "drop",
|
||||
"description": "Remove one orphan, after a stream snapshot.",
|
||||
"callers": "the bus module's process, on the operator's warrant",
|
||||
"callers": [
|
||||
"module:nats"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Warranted"
|
||||
},
|
||||
@@ -191,7 +210,152 @@
|
||||
"dropped"
|
||||
]
|
||||
},
|
||||
"optional": true
|
||||
"optional": true,
|
||||
"class": "warrant"
|
||||
},
|
||||
{
|
||||
"name": "snapshot-kept",
|
||||
"description": "Take the restore point of one module's kept data on the bus: the data whole and the position of each durable consumer the module reads with, keyed by the module, the kept data, its form and the fingerprint it is taken before (design 47 *A module's kept data on the bus*).",
|
||||
"callers": [
|
||||
"holder:node-backup@same-node"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module",
|
||||
"minLength": 1
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data, its local name in the module's manifest",
|
||||
"minLength": 1
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form, the number the holder raises when it changes how it writes it (0 when undeclared)"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint the restore point is taken before",
|
||||
"minLength": 1
|
||||
},
|
||||
"why": {
|
||||
"type": "string",
|
||||
"description": "why it is taken"
|
||||
},
|
||||
"catch-up": {
|
||||
"type": "object",
|
||||
"description": "the catch-up tool the newer manifest declares beside the kept data and its arguments whole, recorded in the restore point (design 47 G 299, 406)",
|
||||
"properties": {
|
||||
"tool": {
|
||||
"type": "string"
|
||||
},
|
||||
"arguments": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"tool"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint"
|
||||
],
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"point": {
|
||||
"$ref": "#/defs/KeptPoint"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed; set alone"
|
||||
}
|
||||
},
|
||||
"description": "the restore point taken, or the error"
|
||||
},
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "restore-kept",
|
||||
"description": "Restore one module's kept data from its restore point beside the live data, never over it: the live data is set aside under a name of its own and the consumers' positions are set back with it. With aside-only it sets the live data aside and restores nothing; with discard-aside, naming data set aside, it removes that data and restores nothing (design 47 G 405).",
|
||||
"callers": [
|
||||
"holder:node-backup@same-node"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module",
|
||||
"minLength": 1
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data, its local name in the module's manifest",
|
||||
"minLength": 1
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form, the number the holder raises when it changes how it writes it (0 when undeclared)"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint the restore point is taken before",
|
||||
"minLength": 1
|
||||
},
|
||||
"snapshot": {
|
||||
"type": "string",
|
||||
"description": "the restore point's name; not with aside-only or discard-aside",
|
||||
"minLength": 1
|
||||
},
|
||||
"why": {
|
||||
"type": "string",
|
||||
"description": "why"
|
||||
},
|
||||
"aside-only": {
|
||||
"type": "boolean",
|
||||
"description": "set the live data aside and restore nothing"
|
||||
},
|
||||
"discard-aside": {
|
||||
"type": "string",
|
||||
"description": "the name of data set aside: remove it and restore nothing"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint"
|
||||
],
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"restored": {
|
||||
"type": "boolean",
|
||||
"description": "the restore point is the live data now"
|
||||
},
|
||||
"aside": {
|
||||
"$ref": "#/defs/Aside"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed; set alone"
|
||||
}
|
||||
},
|
||||
"description": "what was restored and what was set aside, or the error"
|
||||
},
|
||||
"class": "act"
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
@@ -558,6 +722,10 @@
|
||||
"type": "string"
|
||||
},
|
||||
"description": "its subjects, for a stream"
|
||||
},
|
||||
"objects": {
|
||||
"type": "string",
|
||||
"description": "the bus name of the state's <state>-objects, where its large values go (design 47 G 58, 399)"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -565,6 +733,133 @@
|
||||
"storage-type"
|
||||
],
|
||||
"description": "the binding a module receives in its membership for one entry (ADR 0595 §1, §7)"
|
||||
},
|
||||
"KeptPoint": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module",
|
||||
"minLength": 1
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data, its local name in the module's manifest",
|
||||
"minLength": 1
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form, the number the holder raises when it changes how it writes it (0 when undeclared)"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint the restore point is taken before",
|
||||
"minLength": 1
|
||||
},
|
||||
"snapshot": {
|
||||
"type": "string",
|
||||
"description": "the restore point's name"
|
||||
},
|
||||
"consumers": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"stream": {
|
||||
"type": "string",
|
||||
"description": "the stream"
|
||||
},
|
||||
"consumer": {
|
||||
"type": "string",
|
||||
"description": "the durable consumer"
|
||||
},
|
||||
"sequence": {
|
||||
"type": "integer",
|
||||
"description": "its acknowledged position"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"stream",
|
||||
"consumer",
|
||||
"sequence"
|
||||
]
|
||||
},
|
||||
"description": "each durable consumer the module reads with, and its position"
|
||||
},
|
||||
"size": {
|
||||
"type": "integer",
|
||||
"description": "its size in bytes"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when it was taken",
|
||||
"format": "date-time"
|
||||
},
|
||||
"catch-up": {
|
||||
"type": "object",
|
||||
"description": "the catch-up tool and its arguments the restore point records (design 47 G 406)",
|
||||
"properties": {
|
||||
"tool": {
|
||||
"type": "string"
|
||||
},
|
||||
"arguments": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"tool"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint",
|
||||
"snapshot"
|
||||
],
|
||||
"description": "a restore point of one module's kept data on the bus, whole, with its consumers' positions"
|
||||
},
|
||||
"Aside": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "its id, for discard-aside"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "the form it held"
|
||||
},
|
||||
"name": {
|
||||
"type": "string",
|
||||
"description": "the name it is kept under on the bus"
|
||||
},
|
||||
"size": {
|
||||
"type": "integer",
|
||||
"description": "its size in bytes"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when it was set aside",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"module",
|
||||
"kept",
|
||||
"name"
|
||||
],
|
||||
"description": "live kept data a restore set aside, never removed but by discard-aside"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -84,15 +84,26 @@
|
||||
},
|
||||
{
|
||||
"name": "resync",
|
||||
"description": "Read every observer's findings again and raise and clear what differs from the open conditions: the recovery of a keeper that missed a change.",
|
||||
"description": "Ask the observers to state their findings again, every one or the one named, and raise and clear what differs from the open conditions: the recovery of a keeper that missed a change. Each call is written in the hand-act log of the seat mesh-hand-acts (design 47 G 390).",
|
||||
"input": {
|
||||
"properties": {},
|
||||
"type": "object"
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "ask this observer alone; none asks all"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what was raised and cleared again"
|
||||
}
|
||||
},
|
||||
"callers": [
|
||||
"operator",
|
||||
"healers",
|
||||
"sessions"
|
||||
]
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
@@ -113,6 +124,40 @@
|
||||
"body": {
|
||||
"$ref": "#/defs/ConditionEvent"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "findings-asked",
|
||||
"keep": {
|
||||
"max-age-days": 7,
|
||||
"max-mib": 16
|
||||
},
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "the keeper asks every observer, or one, to state its findings (design 47 G 384, 390)",
|
||||
"properties": {
|
||||
"ask": {
|
||||
"type": "string",
|
||||
"description": "the ask's id"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"by": {
|
||||
"type": "string",
|
||||
"description": "who asked: the keeper, or the person or session that called resync"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "to ask one observer; none asks all"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"ask",
|
||||
"at",
|
||||
"by"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"family": {
|
||||
@@ -363,6 +408,14 @@
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"owner": {
|
||||
"type": "string",
|
||||
"description": "the module the finding is about, when not the observer"
|
||||
},
|
||||
"waiting-on": {
|
||||
"type": "string",
|
||||
"description": "what it waits on: a person, a part or a call"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -380,7 +433,67 @@
|
||||
"description": "one finding of the observer that wrote it"
|
||||
}
|
||||
],
|
||||
"description": "every observer's findings, one key per finding; a key written raises or changes the condition of the same key, a key deleted clears it"
|
||||
"description": "every observer's findings, one key per finding, kept in the observer's own state and read only by its owner's read tool; the keeper hears each change as the observer's events finding-written, finding-cleared and findings-stated (design 47 G 383, 434)"
|
||||
},
|
||||
{
|
||||
"name": "findings-views",
|
||||
"template": "state",
|
||||
"description": "the keeper's sources: one key per observer and node, its last stated set with its at, its pending keys and the open asks; deleted when the module leaves the catalog or the node (design 47 G 388)",
|
||||
"key-forms": [
|
||||
{
|
||||
"key": "<observer>.<node>",
|
||||
"description": "one observer on one node",
|
||||
"value": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer"
|
||||
},
|
||||
"observer": {
|
||||
"type": "string"
|
||||
},
|
||||
"node": {
|
||||
"type": "string"
|
||||
},
|
||||
"stated": {
|
||||
"type": "object",
|
||||
"description": "the last findings-stated set",
|
||||
"properties": {
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"findings": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/bodies/Finding"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"pending": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "the keys it cannot judge yet"
|
||||
},
|
||||
"asks": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "the open asks"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"observer",
|
||||
"node"
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"defs": {
|
||||
@@ -643,5 +756,191 @@
|
||||
"change"
|
||||
]
|
||||
}
|
||||
},
|
||||
"bodies": {
|
||||
"Finding": {
|
||||
"type": "object",
|
||||
"description": "one finding as an observer says it: the layout whole, plus scope, id and since (design 47 G 437, 439)",
|
||||
"properties": {
|
||||
"kind": {
|
||||
"type": "string"
|
||||
},
|
||||
"scope": {
|
||||
"type": "string",
|
||||
"description": "the key's first part: <scope>.<id>.<kind> (ADR 0564)"
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the key's second part"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"since": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "since when the finding stands"
|
||||
},
|
||||
"severity": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"urgent",
|
||||
"warning"
|
||||
]
|
||||
},
|
||||
"summary": {
|
||||
"type": "string",
|
||||
"description": "one line"
|
||||
},
|
||||
"headline": {
|
||||
"type": "string"
|
||||
},
|
||||
"explanation": {
|
||||
"type": "string"
|
||||
},
|
||||
"subject": {
|
||||
"$ref": "#/defs/Subject"
|
||||
},
|
||||
"evidence": {
|
||||
"type": "array",
|
||||
"description": "newest first, at most 10",
|
||||
"items": {
|
||||
"$ref": "#/defs/Evidence"
|
||||
}
|
||||
},
|
||||
"source": {
|
||||
"type": "string",
|
||||
"description": "the row, probe or event that saw it"
|
||||
},
|
||||
"observer": {
|
||||
"type": "string",
|
||||
"description": "the module that wrote it"
|
||||
},
|
||||
"owner": {
|
||||
"type": "string",
|
||||
"description": "the module the finding is about, when not the observer"
|
||||
},
|
||||
"waiting-on": {
|
||||
"type": "string",
|
||||
"description": "what it waits on: a person, a part or a call"
|
||||
},
|
||||
"actions": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/Action"
|
||||
}
|
||||
},
|
||||
"needs": {
|
||||
"type": "string"
|
||||
},
|
||||
"resolver": {
|
||||
"type": "string",
|
||||
"description": "self, operator, agent or healer:<name>"
|
||||
},
|
||||
"ref": {
|
||||
"type": "string",
|
||||
"description": "the key's last part when it is not the kind"
|
||||
},
|
||||
"run": {
|
||||
"type": "string",
|
||||
"description": "what of its own saw it last"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"kind",
|
||||
"scope",
|
||||
"id",
|
||||
"at",
|
||||
"since",
|
||||
"severity",
|
||||
"summary",
|
||||
"subject",
|
||||
"source",
|
||||
"observer"
|
||||
]
|
||||
},
|
||||
"FindingWritten": {
|
||||
"$ref": "#/bodies/Finding"
|
||||
},
|
||||
"FindingCleared": {
|
||||
"type": "object",
|
||||
"description": "an observer no longer observes a finding",
|
||||
"properties": {
|
||||
"kind": {
|
||||
"type": "string"
|
||||
},
|
||||
"scope": {
|
||||
"type": "string"
|
||||
},
|
||||
"id": {
|
||||
"type": "string"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"why": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"kind",
|
||||
"scope",
|
||||
"id",
|
||||
"at",
|
||||
"why"
|
||||
]
|
||||
},
|
||||
"FindingsStated": {
|
||||
"type": "object",
|
||||
"description": "every finding an observer observes now, at its start and when asked (design 47 G 384, 439)",
|
||||
"properties": {
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"asked": {
|
||||
"type": "string",
|
||||
"description": "the ask it answers; none at a start"
|
||||
},
|
||||
"findings": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/bodies/Finding"
|
||||
}
|
||||
},
|
||||
"pending": {
|
||||
"type": "array",
|
||||
"description": "the keys the observer cannot judge yet since its start, with their since and bound",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"key": {
|
||||
"type": "string"
|
||||
},
|
||||
"since": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"bound": {
|
||||
"type": "string",
|
||||
"description": "a duration such as 5m"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"key",
|
||||
"since",
|
||||
"bound"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"at",
|
||||
"findings",
|
||||
"pending"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -64,7 +64,9 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"callers": "any caller whose role grants it; the checker asks it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
||||
@@ -176,7 +176,79 @@
|
||||
}
|
||||
}
|
||||
],
|
||||
"description": "The merge check's tries: start one, read one, end one. The checker's own events stay under its own subjects (ADR 0620 §2).",
|
||||
"description": "The merge check's tries: start one, read one, end one. The seat says each check's end as checked and what the checker owes the forge as owed; the checker's other events stay under its own subjects (ADR 0620 \u00a72).",
|
||||
"family": {
|
||||
"name": "mesh-delivery-checker.events",
|
||||
"max-age-days": 7
|
||||
},
|
||||
"events": [
|
||||
{
|
||||
"name": "checked",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a candidate checked: its entries judged at the group's heads (design 47 *What each step says*)",
|
||||
"properties": {
|
||||
"group": {
|
||||
"type": "string",
|
||||
"description": "the group, its branch"
|
||||
},
|
||||
"heads": {
|
||||
"type": "string",
|
||||
"description": "the heads checked, 12 hex digits, as the candidate's revisions are keyed"
|
||||
},
|
||||
"source": {
|
||||
"type": "integer",
|
||||
"description": "the source revision the heads are merged onto"
|
||||
},
|
||||
"catalog": {
|
||||
"type": "integer",
|
||||
"description": "the candidate's catalog graph revision judged, by its number on the seat mesh-catalog"
|
||||
},
|
||||
"verdict": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"pass",
|
||||
"fail",
|
||||
"could not run"
|
||||
],
|
||||
"description": "pass, fail, or could not run when a part the check needs did not answer"
|
||||
},
|
||||
"words": {
|
||||
"type": "string",
|
||||
"description": "what failed first, or the part not heard"
|
||||
},
|
||||
"entries": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/CheckedEntry"
|
||||
},
|
||||
"description": "the entries checked"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"group",
|
||||
"heads",
|
||||
"verdict"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "owed",
|
||||
"subject": "owed.<repository>.<number>",
|
||||
"body": {
|
||||
"$ref": "#/defs/Owed"
|
||||
},
|
||||
"keep": {
|
||||
"max-age-days": 7,
|
||||
"max-mib": 64
|
||||
}
|
||||
}
|
||||
],
|
||||
"holder-events": [
|
||||
{
|
||||
"name": "verdict",
|
||||
@@ -746,5 +818,90 @@
|
||||
"description": "the previews of a head merged onto a trunk",
|
||||
"history": 5
|
||||
}
|
||||
]
|
||||
],
|
||||
"defs": {
|
||||
"Owed": {
|
||||
"type": "object",
|
||||
"description": "the status the checker owes the forge for a head, said under its id and safe to repeat (a status replaces what stands); the forge bridge performs it through the seat git's verb status (design 47 *What the gate owes the forge*)",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the act's id, the same each time it is said again"
|
||||
},
|
||||
"act": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"status"
|
||||
],
|
||||
"description": "the act: always status"
|
||||
},
|
||||
"repository": {
|
||||
"type": "string",
|
||||
"description": "the repository, <owner>/<name>",
|
||||
"minLength": 1
|
||||
},
|
||||
"number": {
|
||||
"type": "integer",
|
||||
"description": "the pull request's number"
|
||||
},
|
||||
"head": {
|
||||
"type": "string",
|
||||
"description": "the pull request's head the status is on",
|
||||
"pattern": "^[0-9a-f]{40}$"
|
||||
},
|
||||
"context": {
|
||||
"type": "string",
|
||||
"description": "its context, mesh/check"
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "pending, success, failure or error"
|
||||
},
|
||||
"description": {
|
||||
"type": "string",
|
||||
"description": "what it says"
|
||||
},
|
||||
"target": {
|
||||
"type": "string",
|
||||
"description": "the page it links to"
|
||||
},
|
||||
"said": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when the checker first said it"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"act",
|
||||
"repository",
|
||||
"number",
|
||||
"head",
|
||||
"context",
|
||||
"state"
|
||||
]
|
||||
},
|
||||
"CheckedEntry": {
|
||||
"type": "object",
|
||||
"description": "one entry of the candidate checked: a module at its fingerprint",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"fp": {
|
||||
"type": "string",
|
||||
"description": "the entry's fingerprint"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node it was composed for, when the check composed it on one"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"fp"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
"grain": "whole",
|
||||
"domain": "Delivery",
|
||||
"decision": "novox/hq ADR 0239",
|
||||
"description": "The delivery gate: reads and steers deliveries, merges and the checks that decide them; the merge is made on the operator's Approve once both checks passed.",
|
||||
"verbs": [
|
||||
{
|
||||
"name": "deliveries",
|
||||
@@ -37,20 +38,8 @@
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what deliveries answers, as its description says"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "times",
|
||||
"description": "Removed in R6 (ADR 0539): refused by name, naming its replacement: the delivery view (nox-delivery): each machine's want and have, and since when",
|
||||
"optional": true,
|
||||
"input": {
|
||||
"properties": {},
|
||||
"type": "object"
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what times answers, as its description says"
|
||||
}
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "show",
|
||||
@@ -70,12 +59,14 @@
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what show answers, as its description says"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "groups",
|
||||
"description": "Every delivery group: its members in order, why each pair is ordered (declared, built by, version skew, engine before controller, by name), its composed check and its state, derived from its members.",
|
||||
"description": "Every delivery group: its members in merge order, its check and its state, derived from its members, and the acts the gate said it owes the forge for it, each with its id and its recorded outcome (design 47 *What the gate owes the forge*). With a group, that group alone, and none for a group it does not know: the forge bridge reads a group's members and catches up on what it owes from here, never from the gate's state.",
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"all": {
|
||||
"description": "\"true\": the groups that ended too",
|
||||
@@ -84,68 +75,74 @@
|
||||
"false"
|
||||
],
|
||||
"type": "string"
|
||||
},
|
||||
"group": {
|
||||
"type": "string",
|
||||
"description": "one group's id: that group alone, ended or not"
|
||||
}
|
||||
},
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what groups answers, as its description says"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "what-if",
|
||||
"description": "Removed in R6 (ADR 0539): refused by name, naming its replacement: the merge check's composition, which composes every machine a change touches",
|
||||
"optional": true,
|
||||
"input": {
|
||||
"properties": {},
|
||||
"type": "object"
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what what-if answers, as its description says"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "checks",
|
||||
"description": "What the mesh's checks said of a pull request's head or of one commit: each of the commit's mesh statuses (mesh/check, the one a main requires from R4e, hq's mesh/repo-check, mesh/delivery, …) with its state, description and when it was set; the merge check's full verdict as the controller said it — each layer's summary, the machine that ran it, when, its build id and its report; and whether the branch's protection would let it merge, every required status being success.",
|
||||
"optional": true,
|
||||
"input": {
|
||||
"properties": {
|
||||
"commit": {
|
||||
"description": "a commit's sha, or the start of one, instead of a pull request",
|
||||
"type": "string"
|
||||
"groups": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/Group"
|
||||
}
|
||||
},
|
||||
"number": {
|
||||
"description": "a pull request's number: its head is read",
|
||||
"type": "string"
|
||||
},
|
||||
"repository": {
|
||||
"description": "owner/repository",
|
||||
"type": "string"
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it could not answer at all; a group it does not know is answered with no groups, never an error"
|
||||
}
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "source",
|
||||
"description": "One watched branch's source revision (design 47 *Watched branches and the catalog graph per branch*: source.<branch> in place of source.main): The source revision the gate holds: every repository it names, its trunk branch and that trunk's head as the gate merged or seeded it, and the group that moved it last. Read, never written: the node-engines read it to call a reverted build's catch-up tool once per repository, never the gate's state (design 47).",
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"branch": {
|
||||
"type": "string",
|
||||
"description": "the watched branch, escaped as a key name is"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"repository"
|
||||
],
|
||||
"type": "object"
|
||||
"branch"
|
||||
]
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what checks answers, as its description says"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "table",
|
||||
"description": "The state table every delivery runs by: each transition with its guard, each state's bound and what healer H2 may do once it has passed; and the machine steps' table.",
|
||||
"input": {
|
||||
"properties": {},
|
||||
"type": "object"
|
||||
"properties": {
|
||||
"group": {
|
||||
"type": "string",
|
||||
"description": "the group that moved the source revision last; absent before the first"
|
||||
},
|
||||
"revision": {
|
||||
"type": "integer",
|
||||
"description": "the source revision's number on the bus; 0 before the first"
|
||||
},
|
||||
"repositories": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/SourceHead"
|
||||
},
|
||||
"description": "every repository the source revision names, by name"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it could not be read"
|
||||
},
|
||||
"branch": {
|
||||
"type": "string",
|
||||
"description": "the watched branch the source revision is of"
|
||||
}
|
||||
}
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what table answers, as its description says"
|
||||
}
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "stalled",
|
||||
@@ -157,137 +154,314 @@
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what stalled answers, as its description says"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "recheck",
|
||||
"description": "Check a rejected or ready delivery again: it goes back to proposed and the controller is asked for its check. With why.",
|
||||
"name": "recovery",
|
||||
"class": "act",
|
||||
"callers": [
|
||||
"operator",
|
||||
"sessions"
|
||||
],
|
||||
"description": "Mark a merge its author names a recovery: the commit and why; the delivery record is marked recovery with the caller the runtime proves, and recovery-merged is said (design 47 G section 305).",
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"description": "the delivery's id",
|
||||
"type": "string"
|
||||
"repository": {
|
||||
"type": "string",
|
||||
"description": "the repository, <owner>/<name>"
|
||||
},
|
||||
"commit": {
|
||||
"type": "string",
|
||||
"description": "the merge commit"
|
||||
},
|
||||
"why": {
|
||||
"description": "why, kept with the transition",
|
||||
"type": "string"
|
||||
"type": "string",
|
||||
"description": "why the merge is a recovery"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"repository",
|
||||
"commit",
|
||||
"why"
|
||||
],
|
||||
"type": "object"
|
||||
]
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what recheck answers, as its description says"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "release",
|
||||
"description": "Removed in R6 (ADR 0539): refused by name, naming its replacement: the assigner's asks (hold, restore, backup, record), answered on the phone or in the delivery view",
|
||||
"optional": true,
|
||||
"input": {
|
||||
"properties": {},
|
||||
"type": "object"
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what release answers, as its description says"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "stop",
|
||||
"description": "Removed in R6 (ADR 0539): refused by name, naming its replacement: a bad fingerprint is held and its canary set back by the assigner (ADR 0429 §6, ADR 0539 clause 18)",
|
||||
"optional": true,
|
||||
"input": {
|
||||
"properties": {},
|
||||
"type": "object"
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what stop answers, as its description says"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "close",
|
||||
"description": "Healer H2's verb: take the one transition the table names for a delivery held past its bound. Refused for any other.",
|
||||
"input": {
|
||||
"properties": {
|
||||
"id": {
|
||||
"description": "the delivery's id",
|
||||
"type": "string"
|
||||
"repository": {
|
||||
"type": "string",
|
||||
"description": "the repository"
|
||||
},
|
||||
"why": {
|
||||
"description": "the condition it answers",
|
||||
"type": "string"
|
||||
"commit": {
|
||||
"type": "string",
|
||||
"description": "the merge commit"
|
||||
},
|
||||
"recovery": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"by": {
|
||||
"type": "string",
|
||||
"description": "the caller the runtime proved"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"why"
|
||||
],
|
||||
"type": "object"
|
||||
"commit",
|
||||
"recovery"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"family": {
|
||||
"name": "mesh-delivery.events",
|
||||
"max-age-days": 7
|
||||
},
|
||||
"events": [
|
||||
{
|
||||
"name": "owed",
|
||||
"subject": "owed.<repository>.<number>",
|
||||
"keep": {
|
||||
"max-age-days": 7,
|
||||
"max-mib": 64
|
||||
},
|
||||
"answer": {
|
||||
"body": {
|
||||
"$ref": "#/defs/Owed"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "pinned",
|
||||
"body": {
|
||||
"$ref": "#/defs/Pins"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "freed",
|
||||
"body": {
|
||||
"$ref": "#/defs/Pins"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "heads-replaced",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "what close answers, as its description says"
|
||||
"description": "a candidate's heads replaced or its pull request closed: its graphs mean nothing any more",
|
||||
"properties": {
|
||||
"group": {
|
||||
"type": "string",
|
||||
"description": "the group"
|
||||
},
|
||||
"heads": {
|
||||
"type": "string",
|
||||
"description": "the candidate's heads, 12 hex digits, as its revisions are keyed"
|
||||
},
|
||||
"repository": {
|
||||
"type": "string",
|
||||
"description": "the member whose head moved or which closed"
|
||||
},
|
||||
"number": {
|
||||
"type": "integer",
|
||||
"description": "its pull request's number"
|
||||
},
|
||||
"head": {
|
||||
"type": "string",
|
||||
"description": "its new head; absent when it closed",
|
||||
"pattern": "^[0-9a-f]{40}$"
|
||||
},
|
||||
"closed": {
|
||||
"type": "boolean",
|
||||
"description": "the pull request closed"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"group",
|
||||
"heads",
|
||||
"repository",
|
||||
"number"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "retire-history",
|
||||
"description": "Removed in R6 (ADR 0539): refused by name, naming its replacement: nothing to retire: the gate keeps no delivery after its merge",
|
||||
"optional": true,
|
||||
"input": {
|
||||
"properties": {},
|
||||
"type": "object"
|
||||
},
|
||||
"answer": {
|
||||
"name": "record-opened",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "what retire-history answers, as its description says"
|
||||
"description": "a delivery record opened: its merge was taken in, and the watchman times it against 24 hours",
|
||||
"properties": {
|
||||
"record": {
|
||||
"type": "string",
|
||||
"description": "the record's id"
|
||||
},
|
||||
"milestone": {
|
||||
"type": "string",
|
||||
"description": "its milestone"
|
||||
},
|
||||
"forge-made": {
|
||||
"type": "boolean",
|
||||
"description": "a merge made at the forge, with no Approve"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"record",
|
||||
"milestone"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "settle",
|
||||
"description": "Ask the operator to settle deliveries held because their merge reached the trunk without a passing check: one ask on the operator's channel for all of them, as an Approve is asked. The verb moves nothing; on the operator's answer each goes to merged, and whether it is on the machines is derived as for any merge (novox/hq ADR 0556). Refused for a delivery not held, or held for another reason, naming why.",
|
||||
"optional": true,
|
||||
"input": {
|
||||
"additionalProperties": false,
|
||||
"name": "record-ended",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a delivery record ended: every present node runs its entries",
|
||||
"properties": {
|
||||
"ids": {
|
||||
"description": "the held deliveries' ids (owner/repository@commit)",
|
||||
"record": {
|
||||
"type": "string",
|
||||
"description": "the record's id"
|
||||
},
|
||||
"milestone": {
|
||||
"type": "string",
|
||||
"description": "its milestone"
|
||||
},
|
||||
"forge-made": {
|
||||
"type": "boolean",
|
||||
"description": "a merge made at the forge, with no Approve"
|
||||
},
|
||||
"away": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "a node away"
|
||||
},
|
||||
"since": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "since when"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"node"
|
||||
]
|
||||
},
|
||||
"minItems": 1,
|
||||
"type": "array"
|
||||
"description": "the nodes away, each with since when; it ends without them"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"record",
|
||||
"milestone"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "filling",
|
||||
"body": {
|
||||
"$ref": "#/defs/Fill"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "full",
|
||||
"body": {
|
||||
"$ref": "#/defs/Fill"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "room",
|
||||
"body": {
|
||||
"$ref": "#/defs/Fill"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "source-moved",
|
||||
"subject": "source-moved.<branch>",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a new source revision of a watched branch (design 47 *The verbs*)",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer"
|
||||
},
|
||||
"branch": {
|
||||
"type": "string"
|
||||
},
|
||||
"revision": {
|
||||
"type": "integer"
|
||||
},
|
||||
"group": {
|
||||
"type": "string",
|
||||
"description": "the group that moved it, when one did"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"branch",
|
||||
"revision"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "recovery-merged",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a merge named a recovery, which the teller passes on to every channel (design 47 G section 305)",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer"
|
||||
},
|
||||
"repository": {
|
||||
"type": "string",
|
||||
"description": "the repository"
|
||||
},
|
||||
"commit": {
|
||||
"type": "string",
|
||||
"description": "the merge commit"
|
||||
},
|
||||
"why": {
|
||||
"description": "why they may be settled, shown to the operator",
|
||||
"type": "string"
|
||||
"type": "string",
|
||||
"description": "why"
|
||||
},
|
||||
"by": {
|
||||
"type": "string",
|
||||
"description": "the caller the runtime proved"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"ids",
|
||||
"v",
|
||||
"repository",
|
||||
"commit",
|
||||
"why"
|
||||
],
|
||||
"type": "object"
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what settle answers, as its description says"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"description": "The delivery gate: reads and steers deliveries, merges and the checks that decide them; the merge is made on the operator's Approve once both checks passed.",
|
||||
"states": [
|
||||
{
|
||||
"name": "source",
|
||||
"template": "state",
|
||||
"key-forms": [
|
||||
{
|
||||
"key": "main",
|
||||
"key": "<branch>",
|
||||
"value": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -313,7 +487,7 @@
|
||||
],
|
||||
"description": "every repository's merged head; its revision is the mesh's source revision"
|
||||
},
|
||||
"description": "the one key, written by the holder alone by compare-and-set"
|
||||
"description": "one key per watched branch, written by the holder alone by compare-and-set; deleted when the last registration watching the branch unwatches it"
|
||||
}
|
||||
],
|
||||
"description": "the mesh's source revision",
|
||||
@@ -529,10 +703,12 @@
|
||||
},
|
||||
"approved": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when (RFC 3339 time)"
|
||||
},
|
||||
"since": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when (RFC 3339 time)"
|
||||
},
|
||||
"waits-for": {
|
||||
@@ -540,6 +716,7 @@
|
||||
},
|
||||
"waits-since": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when (RFC 3339 time)"
|
||||
},
|
||||
"step": {
|
||||
@@ -567,5 +744,345 @@
|
||||
"description": "which merge waits for which",
|
||||
"history": 5
|
||||
}
|
||||
]
|
||||
],
|
||||
"defs": {
|
||||
"Owed": {
|
||||
"type": "object",
|
||||
"description": "one act the gate owes the forge, said once under its id and safe to repeat at the forge (design 47 *What the gate owes the forge*); the forge bridge performs it through the seat git's verb of the same act",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the act's id, the same each time it is said again; a comment and a note line carry it, so the forge holds it once"
|
||||
},
|
||||
"act": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"merge",
|
||||
"status",
|
||||
"view",
|
||||
"comment",
|
||||
"note"
|
||||
],
|
||||
"description": "the act: merge (the seat git's merge-pull), status, view, comment or note"
|
||||
},
|
||||
"repository": {
|
||||
"type": "string",
|
||||
"description": "the repository, <owner>/<name>",
|
||||
"minLength": 1
|
||||
},
|
||||
"number": {
|
||||
"type": "integer",
|
||||
"description": "the pull request's number"
|
||||
},
|
||||
"head": {
|
||||
"type": "string",
|
||||
"description": "the pull request's head the act is for",
|
||||
"pattern": "^[0-9a-f]{40}$"
|
||||
},
|
||||
"group": {
|
||||
"type": "string",
|
||||
"description": "the delivery group the pull request is a member of, for a merge"
|
||||
},
|
||||
"ask": {
|
||||
"type": "string",
|
||||
"description": "the operator's ask that approved the heads, for a merge"
|
||||
},
|
||||
"commit": {
|
||||
"type": "string",
|
||||
"description": "the commit a status or a note line is on; the head when absent",
|
||||
"pattern": "^[0-9a-f]{40}$"
|
||||
},
|
||||
"context": {
|
||||
"type": "string",
|
||||
"description": "a status: its context, such as mesh/merge-gate"
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "a status: its state, pending, success, failure or error"
|
||||
},
|
||||
"description": {
|
||||
"type": "string",
|
||||
"description": "a status: what it says"
|
||||
},
|
||||
"target": {
|
||||
"type": "string",
|
||||
"description": "a status: the page it links to"
|
||||
},
|
||||
"text": {
|
||||
"type": "string",
|
||||
"description": "a comment or the view: the text, markdown"
|
||||
},
|
||||
"line": {
|
||||
"type": "string",
|
||||
"description": "a note line: the one line"
|
||||
},
|
||||
"said": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when the gate first said it"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"act",
|
||||
"repository",
|
||||
"number",
|
||||
"head"
|
||||
]
|
||||
},
|
||||
"Act": {
|
||||
"type": "object",
|
||||
"description": "an act the gate said for a group, with its recorded outcome once the forge bridge said one",
|
||||
"properties": {
|
||||
"owed": {
|
||||
"$ref": "#/defs/Owed"
|
||||
},
|
||||
"outcome": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"performed",
|
||||
"refused",
|
||||
"could not be performed",
|
||||
"undecodable",
|
||||
"dropped"
|
||||
],
|
||||
"description": "the outcome the forge bridge said as owed.ended and the gate recorded; absent while unanswered"
|
||||
},
|
||||
"words": {
|
||||
"type": "string",
|
||||
"description": "the forge's own words for a refusal, the error for an act that could not be performed, why one is undecodable or dropped"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when the outcome was recorded"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"owed"
|
||||
]
|
||||
},
|
||||
"Member": {
|
||||
"type": "object",
|
||||
"description": "one member of a group: a pull request",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the member's delivery id"
|
||||
},
|
||||
"repository": {
|
||||
"type": "string",
|
||||
"description": "the repository, <owner>/<name>"
|
||||
},
|
||||
"number": {
|
||||
"type": "integer",
|
||||
"description": "the pull request's number"
|
||||
},
|
||||
"head": {
|
||||
"type": "string",
|
||||
"description": "its head",
|
||||
"pattern": "^[0-9a-f]{40}$"
|
||||
},
|
||||
"base": {
|
||||
"type": "string",
|
||||
"description": "the branch it merges into"
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "the member's delivery state"
|
||||
},
|
||||
"open": {
|
||||
"type": "boolean",
|
||||
"description": "the pull request is open: not merged, closed or final"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"repository",
|
||||
"number",
|
||||
"head",
|
||||
"state"
|
||||
]
|
||||
},
|
||||
"Group": {
|
||||
"type": "object",
|
||||
"description": "one delivery group: its members, its derived state and the acts the gate said for it",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the group's id, its branch"
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "its state, derived from its members"
|
||||
},
|
||||
"why": {
|
||||
"type": "string",
|
||||
"description": "why it is in that state"
|
||||
},
|
||||
"check": {
|
||||
"type": "string",
|
||||
"description": "the group's check: its verdict, or asked as <id>"
|
||||
},
|
||||
"members": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/Member"
|
||||
},
|
||||
"description": "its members in merge order"
|
||||
},
|
||||
"acts": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/Act"
|
||||
},
|
||||
"description": "the acts the gate said for it, each with its id and its recorded outcome; an id said and not answered is the forge bridge's to perform"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"state",
|
||||
"members",
|
||||
"acts"
|
||||
]
|
||||
},
|
||||
"Fill": {
|
||||
"type": "object",
|
||||
"description": "the delivery records' ledger's fill against its cap",
|
||||
"properties": {
|
||||
"store": {
|
||||
"type": "string",
|
||||
"description": "the kept data, by its name in the holder's manifest"
|
||||
},
|
||||
"bytes": {
|
||||
"type": "integer"
|
||||
},
|
||||
"cap": {
|
||||
"type": "integer",
|
||||
"description": "bytes"
|
||||
},
|
||||
"refused": {
|
||||
"type": "string",
|
||||
"description": "what full refuses, such as the next record"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"store",
|
||||
"bytes",
|
||||
"cap"
|
||||
]
|
||||
},
|
||||
"Pins": {
|
||||
"type": "object",
|
||||
"description": "the graph revisions a delivery record starts or stops pointing at",
|
||||
"properties": {
|
||||
"record": {
|
||||
"type": "string",
|
||||
"description": "the record's id"
|
||||
},
|
||||
"milestone": {
|
||||
"type": "string",
|
||||
"description": "the record's milestone"
|
||||
},
|
||||
"catalog": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "integer"
|
||||
},
|
||||
"description": "catalog graph revisions, by their number on the seat mesh-catalog"
|
||||
},
|
||||
"assignment": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "integer"
|
||||
},
|
||||
"description": "assignment graph revisions, by their number on the seat mesh-wants"
|
||||
},
|
||||
"why": {
|
||||
"type": "string",
|
||||
"description": "on freed: the record ended past its retention, or was removed by hand"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"record",
|
||||
"milestone"
|
||||
]
|
||||
},
|
||||
"Ask": {
|
||||
"type": "object",
|
||||
"description": "the one Approve ask of a milestone (ADR 0493 \u00a79), said apart from each delivery's transition",
|
||||
"properties": {
|
||||
"milestone": {
|
||||
"type": "string",
|
||||
"description": "the milestone"
|
||||
},
|
||||
"ask": {
|
||||
"type": "string",
|
||||
"description": "the ask's id"
|
||||
},
|
||||
"group": {
|
||||
"type": "string",
|
||||
"description": "its delivery group"
|
||||
},
|
||||
"heads": {
|
||||
"type": "object",
|
||||
"additionalProperties": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "repository to the head asked"
|
||||
},
|
||||
"answer": {
|
||||
"type": "string",
|
||||
"description": "on answered: approve or decline"
|
||||
},
|
||||
"by": {
|
||||
"type": "string",
|
||||
"description": "on answered: who answered"
|
||||
},
|
||||
"why": {
|
||||
"type": "string",
|
||||
"description": "on withdrawn: why, such as a new head of a member"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"milestone",
|
||||
"ask",
|
||||
"group"
|
||||
]
|
||||
},
|
||||
"SourceHead": {
|
||||
"type": "object",
|
||||
"description": "one repository of the source revision: its trunk branch and that trunk's head",
|
||||
"properties": {
|
||||
"repository": {
|
||||
"type": "string",
|
||||
"description": "the repository, <owner>/<name>"
|
||||
},
|
||||
"trunk": {
|
||||
"type": "string",
|
||||
"description": "its trunk branch, such as main"
|
||||
},
|
||||
"head": {
|
||||
"type": "string",
|
||||
"description": "the trunk's head the source revision names",
|
||||
"pattern": "^[0-9a-f]{40}$"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"repository",
|
||||
"trunk",
|
||||
"head"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -407,6 +407,14 @@
|
||||
"module": {
|
||||
"type": "string"
|
||||
},
|
||||
"branch": {
|
||||
"type": "string",
|
||||
"description": "the watched branch this node runs the module from; absent, the first watched branch of the module's registration (design 47 G 14)"
|
||||
},
|
||||
"build": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint of the build the node runs; absent, the newest delivered of the branch (design 47 G 78, 402)"
|
||||
},
|
||||
"ports": {
|
||||
"type": "object",
|
||||
"additionalProperties": {
|
||||
@@ -636,6 +644,14 @@
|
||||
"module": {
|
||||
"type": "string"
|
||||
},
|
||||
"branch": {
|
||||
"type": "string",
|
||||
"description": "for place, the watched branch the node runs the module from; absent, the first watched branch of the module's registration (design 47 G 14)"
|
||||
},
|
||||
"build": {
|
||||
"type": "string",
|
||||
"description": "for place, the build of that branch the node runs, a return to an earlier build being this one value; absent, the newest delivered of the branch (ADR 0666 section 24)"
|
||||
},
|
||||
"ports": {
|
||||
"type": "object",
|
||||
"additionalProperties": {
|
||||
|
||||
@@ -597,7 +597,9 @@
|
||||
"name": "retire",
|
||||
"optional": true,
|
||||
"description": "Retire one module's own secret, by node, module and name, on the operator's warrant bound to exactly those three (design 32 *A value no longer read*). Emits own-retired.",
|
||||
"callers": "the holder of the seat mesh-config alone",
|
||||
"callers": [
|
||||
"seat:mesh-config"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
||||
@@ -51,6 +51,160 @@
|
||||
"type": "object",
|
||||
"description": "what a bus upgrade would do, read only"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "revision",
|
||||
"description": "The assignment half of the revision view (ADR 0656 \u00a76): one assignment graph revision, named by its own number and naming its inputs, with its entries' digests; the trunk's newest when none is named, or a candidate's for its group and heads. Reads only.",
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"revision": {
|
||||
"type": "integer",
|
||||
"description": "a kept revision; absent: the newest of trunk, or of the candidate named"
|
||||
},
|
||||
"group": {
|
||||
"type": "string",
|
||||
"description": "a candidate's group"
|
||||
},
|
||||
"heads": {
|
||||
"type": "string",
|
||||
"description": "a candidate's heads"
|
||||
}
|
||||
}
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"revision": {
|
||||
"$ref": "#/defs/AssignmentRevision"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"revision"
|
||||
]
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "entry",
|
||||
"description": "One entry of an assignment graph revision whole, by its digest or by its node and module in a revision, with the seat rule that gave each edge. Reads only.",
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"revision": {
|
||||
"type": "integer",
|
||||
"description": "a kept revision; absent: the newest of trunk, or of the candidate named"
|
||||
},
|
||||
"group": {
|
||||
"type": "string",
|
||||
"description": "a candidate's group"
|
||||
},
|
||||
"heads": {
|
||||
"type": "string",
|
||||
"description": "a candidate's heads"
|
||||
},
|
||||
"digest": {
|
||||
"type": "string"
|
||||
},
|
||||
"node": {
|
||||
"type": "string"
|
||||
},
|
||||
"module": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"digest": {
|
||||
"type": "string"
|
||||
},
|
||||
"entry": {
|
||||
"$ref": "#/defs/AssignmentEntry"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"digest",
|
||||
"entry"
|
||||
]
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "difference",
|
||||
"description": "A change's graph difference, which is its delivery: two kept revisions compared, or a candidate's newest against trunk's newest, with the changed module versions, the touched nodes and the order as tiers. Reads only.",
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"from": {
|
||||
"type": "integer"
|
||||
},
|
||||
"to": {
|
||||
"type": "integer"
|
||||
},
|
||||
"group": {
|
||||
"type": "string"
|
||||
},
|
||||
"heads": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Difference"
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "input",
|
||||
"class": "read",
|
||||
"callers": [
|
||||
"seat:node-build-go",
|
||||
"seat:node-build-node",
|
||||
"seat:node-build-image"
|
||||
],
|
||||
"description": "A step's input by its digest, as the assigner keeps it for the composition step it asked a build seat to run (design 47 G section 354).",
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"digest": {
|
||||
"type": "string",
|
||||
"description": "the input's sha256"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"digest"
|
||||
]
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"digest": {
|
||||
"type": "string",
|
||||
"description": "the input's sha256"
|
||||
},
|
||||
"input": {
|
||||
"type": "string",
|
||||
"description": "the input's exact bytes, base64"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"digest",
|
||||
"input"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"accepts": [
|
||||
{
|
||||
"name": "step",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepRun"
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-pipeline-runner"
|
||||
]
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
@@ -59,6 +213,220 @@
|
||||
"body": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "assignment-revision",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "an assignment graph revision kept",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer"
|
||||
},
|
||||
"revision": {
|
||||
"type": "integer"
|
||||
},
|
||||
"kind": {
|
||||
"type": "string"
|
||||
},
|
||||
"cause": {
|
||||
"type": "string"
|
||||
},
|
||||
"group": {
|
||||
"type": "string"
|
||||
},
|
||||
"heads": {
|
||||
"type": "string"
|
||||
},
|
||||
"catalogs": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/CatalogOf"
|
||||
},
|
||||
"minItems": 1,
|
||||
"description": "the catalog graph revision of each watched branch a placement names, which the entries come from"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"revision",
|
||||
"kind",
|
||||
"catalogs"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "difference",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a difference worked out between two revisions",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer"
|
||||
},
|
||||
"from": {
|
||||
"type": "integer"
|
||||
},
|
||||
"to": {
|
||||
"type": "integer"
|
||||
},
|
||||
"source": {
|
||||
"type": "integer"
|
||||
},
|
||||
"group": {
|
||||
"type": "string"
|
||||
},
|
||||
"heads": {
|
||||
"type": "string"
|
||||
},
|
||||
"changes": {
|
||||
"type": "integer",
|
||||
"description": "how many module versions it changes"
|
||||
},
|
||||
"nodes": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"from",
|
||||
"to"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "wanted",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "an entry written as a want, from a trunk revision only",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer"
|
||||
},
|
||||
"node": {
|
||||
"type": "string"
|
||||
},
|
||||
"module": {
|
||||
"type": "string"
|
||||
},
|
||||
"fp": {
|
||||
"type": "string"
|
||||
},
|
||||
"revision": {
|
||||
"type": "integer"
|
||||
},
|
||||
"source": {
|
||||
"type": "integer"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"node",
|
||||
"module",
|
||||
"fp",
|
||||
"revision"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "wait-held",
|
||||
"body": {
|
||||
"$ref": "#/defs/Wait"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "wait-ended",
|
||||
"body": {
|
||||
"$ref": "#/defs/Wait"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "filling",
|
||||
"body": {
|
||||
"$ref": "#/defs/Fill"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "full",
|
||||
"body": {
|
||||
"$ref": "#/defs/Fill"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "room",
|
||||
"body": {
|
||||
"$ref": "#/defs/Fill"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "step-ended",
|
||||
"subject": "step-ended.<node>",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepEnded"
|
||||
},
|
||||
"keep": {
|
||||
"max-age-days": 90,
|
||||
"max-mib": 32
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "version-delivered",
|
||||
"keep": {
|
||||
"max-age-days": 90,
|
||||
"max-mib": 64
|
||||
},
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a version delivered to every present machine that places it, and healthy (design 47 G section 376)",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"version": {
|
||||
"type": "string",
|
||||
"description": "MAJOR.MINOR.PATCH"
|
||||
},
|
||||
"parts": {
|
||||
"type": "object",
|
||||
"additionalProperties": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "the digest of each of its parts, by artifact reference"
|
||||
},
|
||||
"away": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "the machines away when it was said"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"module",
|
||||
"version",
|
||||
"parts"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"family": {
|
||||
@@ -120,6 +488,17 @@
|
||||
},
|
||||
"self": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"version": {
|
||||
"type": "string",
|
||||
"description": "the module's released version, for people; none for a build of another watched branch (design 47 G section 379)"
|
||||
},
|
||||
"parts": {
|
||||
"type": "object",
|
||||
"additionalProperties": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "the digest of each of the module's parts, by artifact reference; the node-engine fetches and checks each part by it (design 47 G section 379)"
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -279,6 +658,577 @@
|
||||
],
|
||||
"history": 5,
|
||||
"description": "composition verdicts of a group's check; the checker reads them"
|
||||
},
|
||||
{
|
||||
"name": "assignment-revisions",
|
||||
"template": "objects",
|
||||
"description": "the assignment graph revisions, each a list of its entries' digests naming its inputs, and each entry once by its digest; a revision is kept while a delivery record pins it or it is current (design 47)",
|
||||
"key-forms": [
|
||||
{
|
||||
"key": "trunk.<revision>",
|
||||
"value": {
|
||||
"$ref": "#/defs/AssignmentRevision"
|
||||
},
|
||||
"description": "a trunk revision"
|
||||
},
|
||||
{
|
||||
"key": "candidate.<group>.<heads>",
|
||||
"value": {
|
||||
"$ref": "#/defs/AssignmentRevision"
|
||||
},
|
||||
"description": "a candidate's newest revision, dropped on heads-replaced"
|
||||
},
|
||||
{
|
||||
"key": "entry.<digest>",
|
||||
"value": {
|
||||
"$ref": "#/defs/AssignmentEntry"
|
||||
},
|
||||
"description": "an entry, written once, removed when no kept revision lists it"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "inputs",
|
||||
"template": "state",
|
||||
"history": 1,
|
||||
"description": "a step's input, named by its write time and its sha256 (design 47 G section 354)",
|
||||
"key-forms": [
|
||||
{
|
||||
"key": "<time>.<digest>",
|
||||
"value": {
|
||||
"type": "string",
|
||||
"description": "the input's bytes, base64"
|
||||
},
|
||||
"description": "one input"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"defs": {
|
||||
"Edge": {
|
||||
"type": "object",
|
||||
"description": "an edge from one module version on a node to another: provisioning, contribution, or an acting part's version that is to act on it in a step (ADR 0656)",
|
||||
"properties": {
|
||||
"kind": {
|
||||
"type": "string",
|
||||
"description": "provisioning, contribution or acting"
|
||||
},
|
||||
"node": {
|
||||
"type": "string"
|
||||
},
|
||||
"module": {
|
||||
"type": "string"
|
||||
},
|
||||
"fp": {
|
||||
"type": "string",
|
||||
"description": "the other end's fingerprint"
|
||||
},
|
||||
"provision": {
|
||||
"type": "string",
|
||||
"description": "for provisioning, the provision"
|
||||
},
|
||||
"seat": {
|
||||
"type": "string",
|
||||
"description": "for contribution, the seat it contributes to; for acting, the seat whose rule gave the edge"
|
||||
},
|
||||
"step": {
|
||||
"type": "string",
|
||||
"description": "for acting, the step: take-in, validate, check, build, compose, grant or place"
|
||||
},
|
||||
"bound": {
|
||||
"type": "string",
|
||||
"description": "for acting, how long the new version may take before it acts"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"kind",
|
||||
"node",
|
||||
"module"
|
||||
]
|
||||
},
|
||||
"AssignmentEntry": {
|
||||
"type": "object",
|
||||
"description": "one module version on a node of an assignment graph revision, stored once by its digest (ADR 0656)",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout version"
|
||||
},
|
||||
"node": {
|
||||
"type": "string"
|
||||
},
|
||||
"module": {
|
||||
"type": "string"
|
||||
},
|
||||
"branch": {
|
||||
"type": "string",
|
||||
"description": "the watched branch its placement names, whose catalog graph the entry comes from (design 47 lines 523-525)"
|
||||
},
|
||||
"fp": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint it is to run"
|
||||
},
|
||||
"catalog": {
|
||||
"type": "string",
|
||||
"description": "the digest of its catalog graph entry"
|
||||
},
|
||||
"edges": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/Edge"
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"node",
|
||||
"module",
|
||||
"branch",
|
||||
"fp",
|
||||
"catalog"
|
||||
]
|
||||
},
|
||||
"NodeEntryRef": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"node": {
|
||||
"type": "string"
|
||||
},
|
||||
"module": {
|
||||
"type": "string"
|
||||
},
|
||||
"digest": {
|
||||
"type": "string",
|
||||
"description": "the entry's digest, its object's name"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"node",
|
||||
"module",
|
||||
"digest"
|
||||
]
|
||||
},
|
||||
"AssignmentRevision": {
|
||||
"type": "object",
|
||||
"description": "an assignment graph revision: the list of its entries' digests and the inputs it was computed from, so it can be computed again and compared",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout version"
|
||||
},
|
||||
"revision": {
|
||||
"type": "integer",
|
||||
"description": "counted by its holder"
|
||||
},
|
||||
"kind": {
|
||||
"type": "string",
|
||||
"description": "trunk or candidate"
|
||||
},
|
||||
"group": {
|
||||
"type": "string"
|
||||
},
|
||||
"heads": {
|
||||
"type": "string"
|
||||
},
|
||||
"catalogs": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/CatalogOf"
|
||||
},
|
||||
"minItems": 1,
|
||||
"description": "the catalog graph revision of each watched branch a placement names, which the entries come from"
|
||||
},
|
||||
"placements": {
|
||||
"type": "string",
|
||||
"description": "the digest of the placements it was computed from"
|
||||
},
|
||||
"capabilities": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"node": {
|
||||
"type": "string"
|
||||
},
|
||||
"digest": {
|
||||
"type": "string",
|
||||
"description": "the digest of the node's capability reading"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"node",
|
||||
"digest"
|
||||
]
|
||||
}
|
||||
},
|
||||
"cause": {
|
||||
"type": "string",
|
||||
"description": "what made it: catalog-revision, placement-changed or capabilities-changed"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"entries": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/NodeEntryRef"
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"revision",
|
||||
"kind",
|
||||
"catalogs",
|
||||
"placements",
|
||||
"entries"
|
||||
]
|
||||
},
|
||||
"Change": {
|
||||
"type": "object",
|
||||
"description": "one module on a node whose version differs between two revisions",
|
||||
"properties": {
|
||||
"node": {
|
||||
"type": "string"
|
||||
},
|
||||
"module": {
|
||||
"type": "string"
|
||||
},
|
||||
"from": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint before; absent when it is new there"
|
||||
},
|
||||
"to": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint after; absent when it goes"
|
||||
},
|
||||
"edges": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/Edge"
|
||||
},
|
||||
"description": "the edges that moved"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"node",
|
||||
"module"
|
||||
]
|
||||
},
|
||||
"Difference": {
|
||||
"type": "object",
|
||||
"description": "two assignment graph revisions compared: a change's delivery, with its order read off the edges and no plan stored (ADR 0656)",
|
||||
"properties": {
|
||||
"from": {
|
||||
"type": "integer",
|
||||
"description": "the revision compared from"
|
||||
},
|
||||
"to": {
|
||||
"type": "integer",
|
||||
"description": "the revision compared to"
|
||||
},
|
||||
"group": {
|
||||
"type": "string"
|
||||
},
|
||||
"heads": {
|
||||
"type": "string"
|
||||
},
|
||||
"changes": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/Change"
|
||||
}
|
||||
},
|
||||
"nodes": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "the nodes it touches"
|
||||
},
|
||||
"tiers": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/NodeEntryRef"
|
||||
}
|
||||
},
|
||||
"description": "the order as a view: each tier the changes whose acting parts acted in the tiers before it (ADR 0603 \u00a76 as ADR 0656 changes it)"
|
||||
},
|
||||
"refused": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string"
|
||||
},
|
||||
"why": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"why"
|
||||
]
|
||||
},
|
||||
"description": "a module whose fingerprint changed while the difference is empty, refused by name"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"from",
|
||||
"to",
|
||||
"changes"
|
||||
]
|
||||
},
|
||||
"Wait": {
|
||||
"type": "object",
|
||||
"description": "a step's wait the assigner holds: placing, wanting or composing until an acting part's new version runs",
|
||||
"properties": {
|
||||
"step": {
|
||||
"type": "string"
|
||||
},
|
||||
"part": {
|
||||
"type": "string",
|
||||
"description": "the acting part waited for"
|
||||
},
|
||||
"version": {
|
||||
"type": "string",
|
||||
"description": "its new version's fingerprint"
|
||||
},
|
||||
"node": {
|
||||
"type": "string"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the entry that waits"
|
||||
},
|
||||
"fp": {
|
||||
"type": "string"
|
||||
},
|
||||
"since": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"bound": {
|
||||
"type": "string",
|
||||
"description": "a duration such as 30m"
|
||||
},
|
||||
"how": {
|
||||
"type": "string",
|
||||
"description": "on wait-ended: ran or released"
|
||||
},
|
||||
"by": {
|
||||
"type": "string",
|
||||
"description": "on a release, who released it and why"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"step",
|
||||
"part",
|
||||
"version",
|
||||
"module",
|
||||
"since"
|
||||
]
|
||||
},
|
||||
"Fill": {
|
||||
"type": "object",
|
||||
"description": "a store's fill against its cap",
|
||||
"properties": {
|
||||
"store": {
|
||||
"type": "string",
|
||||
"description": "the kept data, by its name in the holder's manifest"
|
||||
},
|
||||
"bytes": {
|
||||
"type": "integer"
|
||||
},
|
||||
"cap": {
|
||||
"type": "integer",
|
||||
"description": "bytes"
|
||||
},
|
||||
"refused": {
|
||||
"type": "string",
|
||||
"description": "what full refuses"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"store",
|
||||
"bytes",
|
||||
"cap"
|
||||
]
|
||||
},
|
||||
"StepRun": {
|
||||
"type": "object",
|
||||
"description": "the composition step of one module's pipeline (design 47 *Pipeline steps and the policy*, *The pipeline makes the check*): the assigner composes each machine's declaration at the change's heads with the composer built from them, in the build seat's sandbox, and refuses a change in which two modules own one path",
|
||||
"properties": {
|
||||
"pipeline": {
|
||||
"type": "string",
|
||||
"description": "the runner's pipeline key, <branch>.<revision>.<module>, a branch escaped as a key's name is"
|
||||
},
|
||||
"step": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"composition"
|
||||
]
|
||||
},
|
||||
"module": {
|
||||
"type": "string"
|
||||
},
|
||||
"branch": {
|
||||
"type": "string",
|
||||
"description": "the watched branch, or the branch of a run on request"
|
||||
},
|
||||
"commit": {
|
||||
"type": "string",
|
||||
"description": "the commit the step runs at"
|
||||
},
|
||||
"revision": {
|
||||
"type": "integer",
|
||||
"description": "the catalog graph revision of the branch the pipeline runs for"
|
||||
},
|
||||
"source": {
|
||||
"type": "integer",
|
||||
"description": "the source revision of the watched branch; absent for a run on request"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the module's build-input fingerprint at the commit"
|
||||
},
|
||||
"run": {
|
||||
"type": "string",
|
||||
"description": "the run on request's id: its composition writes no want (ADR 0666 section 18)"
|
||||
},
|
||||
"rerun": {
|
||||
"type": "boolean",
|
||||
"description": "the step is asked again by the runner's rerun"
|
||||
},
|
||||
"by": {
|
||||
"type": "string",
|
||||
"description": "for a rerun, the caller the runtime proved"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"pipeline",
|
||||
"step",
|
||||
"module",
|
||||
"branch",
|
||||
"commit",
|
||||
"fingerprint"
|
||||
]
|
||||
},
|
||||
"StepEnded": {
|
||||
"type": "object",
|
||||
"description": "the composition step's end, said by the assigner on the node it runs on (ADR 0666 sections 7, 21): the runner takes it only from that holder's account, naming the ask, the commit and the fingerprint it was asked at",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout version"
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the ask's id"
|
||||
},
|
||||
"pipeline": {
|
||||
"type": "string"
|
||||
},
|
||||
"step": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"composition"
|
||||
]
|
||||
},
|
||||
"module": {
|
||||
"type": "string"
|
||||
},
|
||||
"commit": {
|
||||
"type": "string"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node the assigner ran it on, as in the subject"
|
||||
},
|
||||
"outcome": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"passed",
|
||||
"failed",
|
||||
"nothing to run",
|
||||
"could not run"
|
||||
],
|
||||
"description": "never passed for a step that composed nothing"
|
||||
},
|
||||
"said": {
|
||||
"type": "string",
|
||||
"description": "why it failed or could not run: the two modules owning one path, the part not heard"
|
||||
},
|
||||
"warnings": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "a node asleep, passed with a warning (ADR 0593 section 9)"
|
||||
},
|
||||
"rerun": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"by": {
|
||||
"type": "string",
|
||||
"description": "for a rerun, the caller the runtime proved"
|
||||
},
|
||||
"started": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"ended": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"pipeline",
|
||||
"step",
|
||||
"module",
|
||||
"commit",
|
||||
"fingerprint",
|
||||
"node",
|
||||
"outcome"
|
||||
]
|
||||
},
|
||||
"CatalogOf": {
|
||||
"type": "object",
|
||||
"description": "one catalog graph revision of a watched branch the revision was computed from (design 47 lines 1416-1418)",
|
||||
"properties": {
|
||||
"branch": {
|
||||
"type": "string",
|
||||
"description": "the watched branch"
|
||||
},
|
||||
"revision": {
|
||||
"type": "integer",
|
||||
"description": "that branch's catalog graph revision"
|
||||
},
|
||||
"source": {
|
||||
"type": "integer",
|
||||
"description": "the source revision of that branch it carries"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"branch",
|
||||
"revision"
|
||||
]
|
||||
}
|
||||
},
|
||||
"acts": [
|
||||
{
|
||||
"step": "place",
|
||||
"on": "every"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -159,6 +159,86 @@
|
||||
}
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
{
|
||||
"name": "machine-away",
|
||||
"subject": "machine-away.<machine>",
|
||||
"keep": {
|
||||
"max-age-days": 90,
|
||||
"max-mib": 16
|
||||
},
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "the watchman's presence key of a machine expired (ADR 0564 4); published by the holder of this seat alone for another machine (design 47 G 436)",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"machine": {
|
||||
"type": "string",
|
||||
"description": "the machine whose presence changed"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"last-heard": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when the machine was last heard"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"machine",
|
||||
"at",
|
||||
"last-heard"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "machine-back",
|
||||
"subject": "machine-back.<machine>",
|
||||
"keep": {
|
||||
"max-age-days": 90,
|
||||
"max-mib": 16
|
||||
},
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a machine is heard again after it was away",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"machine": {
|
||||
"type": "string",
|
||||
"description": "the machine whose presence changed"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"last-heard": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when the machine was last heard"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"machine",
|
||||
"at",
|
||||
"last-heard"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"family": {
|
||||
"name": "mesh-watchdogs.events",
|
||||
"max-age-days": 7
|
||||
},
|
||||
"states": [
|
||||
{
|
||||
"name": "presence",
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
"verbs": [
|
||||
{
|
||||
"name": "backed-up",
|
||||
"description": "What this machine backs up: each module, what it declared, its last good night, how many restore points are kept and the repository's size.",
|
||||
"description": "What this machine backs up: each module, what it declared, its last good night, how many restore points are kept and the repository's size. Also each module's restore points of its kept data on the bus (the kept data, the form, the fingerprint each was taken before) and the data set aside at each restore, with its size.",
|
||||
"replaces": [
|
||||
"restic snapshots"
|
||||
],
|
||||
@@ -24,7 +24,7 @@
|
||||
},
|
||||
{
|
||||
"name": "now",
|
||||
"description": "Take a backup now, of one module or of every module on this machine — before a migration, a retirement or anything else that could go wrong.",
|
||||
"description": "Take a backup now, of one module or of every module on this machine — before a migration, a retirement or anything else that could go wrong. With kept, a restore point of one kept data on the bus instead, said by the event ended.",
|
||||
"replaces": [
|
||||
"restic backup"
|
||||
],
|
||||
@@ -33,14 +33,42 @@
|
||||
"module": {
|
||||
"description": "one module (optional)",
|
||||
"type": "string"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "one kept data of the module on the bus, its local name: its restore point is taken by the bus module's account, of the node holding mesh-broker"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "with kept: its form now"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "with kept: the fingerprint the restore point is taken before"
|
||||
},
|
||||
"catch-up": {
|
||||
"type": "object",
|
||||
"description": "with kept: the catch-up tool the newer manifest declares beside it and its arguments whole, recorded in the restore point (design 47 G 299, 406)",
|
||||
"properties": {
|
||||
"tool": {
|
||||
"type": "string"
|
||||
},
|
||||
"arguments": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"tool"
|
||||
]
|
||||
}
|
||||
},
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "restore",
|
||||
"description": "Restore one module's data from a restore point BESIDE the live data, never over it: each directory as \u003cpath\u003e.restored-\u003cdate\u003e. Swapping it in is a person's act. Lists the restore points when none is named.",
|
||||
"description": "Restore one module's data from a restore point BESIDE the live data, never over it: each directory as <path>.restored-<date>. Swapping it in is a person's act. Lists the restore points when none is named. With kept, the restore point of one kept data on the bus by its module, kept data and form, the live data set aside and never removed, said by the event restored.",
|
||||
"replaces": [
|
||||
"restic restore"
|
||||
],
|
||||
@@ -57,13 +85,96 @@
|
||||
"snapshot": {
|
||||
"description": "the restore point (from `backed-up`; the newest when omitted)",
|
||||
"type": "string"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "one kept data of the module on the bus, its local name: its restore point is taken by the bus module's account, of the node holding mesh-broker"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "with kept: its form now"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "with kept: the fingerprint the restore point is taken before"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module"
|
||||
],
|
||||
"type": "object"
|
||||
},
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "aside",
|
||||
"description": "Set one module's live kept data on the bus aside under a name of its own and restore nothing, after the node agent stopped the newer build (design 47 G 297, 405); the data set aside is listed by backed-up and removed only by discard-aside.",
|
||||
"class": "act",
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "one kept data of the module on the bus, its local name: its restore point is taken by the bus module's account, of the node holding mesh-broker"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "with kept: its form now"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "with kept: the fingerprint the restore point is taken before"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint"
|
||||
]
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"aside": {
|
||||
"type": "string",
|
||||
"description": "the name the live data is set aside under"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed; set alone"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "discard-aside",
|
||||
"description": "Remove data a restore set aside, on a person's call alone; writes the act, who and why in the hand-act log of the seat mesh-hand-acts.",
|
||||
"callers": [
|
||||
"operator"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the aside's id, as backed-up lists it"
|
||||
},
|
||||
"why": {
|
||||
"type": "string",
|
||||
"description": "why"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"why"
|
||||
]
|
||||
},
|
||||
"class": "act"
|
||||
}
|
||||
],
|
||||
"receives": [
|
||||
@@ -77,5 +188,103 @@
|
||||
"comment": "#",
|
||||
"dirs": true
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
{
|
||||
"name": "ended",
|
||||
"subject": "ended.<node>.<module>.<kept>",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a restore point of a kept data on the bus taken, done or failed",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint"
|
||||
},
|
||||
"outcome": {
|
||||
"enum": [
|
||||
"done",
|
||||
"failed"
|
||||
]
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint",
|
||||
"outcome"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "restored",
|
||||
"subject": "restored.<node>.<module>.<kept>",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a kept data on the bus restored from its restore point beside the live data, done or failed",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint"
|
||||
},
|
||||
"outcome": {
|
||||
"enum": [
|
||||
"done",
|
||||
"failed"
|
||||
]
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint",
|
||||
"outcome"
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -7,24 +7,63 @@
|
||||
"decision": "novox/hq ADR 0525, ADR 0536, ADR 0553",
|
||||
"pulled-by-kind": true,
|
||||
"yields": true,
|
||||
"acts": [
|
||||
{
|
||||
"step": "build",
|
||||
"on": "go",
|
||||
"bound": "60m"
|
||||
}
|
||||
],
|
||||
"accepts": [
|
||||
{
|
||||
"name": "delivery",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
}
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-builds"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "check",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
}
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-delivery-checker",
|
||||
"seat:mesh-catalog",
|
||||
"seat:mesh-pipeline-runner"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "step",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-pipeline-runner"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "recheck",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
}
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-delivery-checker"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "run",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-pipeline-runner",
|
||||
"seat:mesh-catalog",
|
||||
"seat:mesh-wants",
|
||||
"seat:mesh-delivery-checker"
|
||||
]
|
||||
}
|
||||
],
|
||||
"description": "The Go build module on a node: it takes the asks of the builder and the checker, runs them as steps and answers.",
|
||||
@@ -58,6 +97,13 @@
|
||||
},
|
||||
"description": "whether a node is paused"
|
||||
},
|
||||
{
|
||||
"key": "dropped.<id>",
|
||||
"value": {
|
||||
"$ref": "#/defs/Drop"
|
||||
},
|
||||
"description": "an ask its caller no longer waits for"
|
||||
},
|
||||
{
|
||||
"key": "capacity.<node>",
|
||||
"value": {
|
||||
@@ -83,6 +129,25 @@
|
||||
],
|
||||
"description": "the toolchains the nodes report",
|
||||
"history": 1
|
||||
},
|
||||
{
|
||||
"name": "detected-steps",
|
||||
"template": "state",
|
||||
"history": 1,
|
||||
"description": "each artifact's detected steps, one key per artifact (design 47 G section 326, section 414)",
|
||||
"key-forms": [
|
||||
{
|
||||
"key": "<module>.<artifact>",
|
||||
"value": {
|
||||
"$ref": "#/defs/DetectedSteps"
|
||||
},
|
||||
"description": "an artifact's detected steps"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
],
|
||||
"family": {
|
||||
"name": "node-build-go.events",
|
||||
"max-age-days": 7
|
||||
}
|
||||
}
|
||||
|
||||
@@ -12,19 +12,37 @@
|
||||
"name": "delivery",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
}
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-builds"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "check",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
}
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-delivery-checker"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "step",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-pipeline-runner"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "recheck",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
}
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-delivery-checker"
|
||||
]
|
||||
}
|
||||
],
|
||||
"description": "The image build module on a node: it takes the asks of the builder and the checker, runs them as steps and answers.",
|
||||
@@ -58,6 +76,13 @@
|
||||
},
|
||||
"description": "whether a node is paused"
|
||||
},
|
||||
{
|
||||
"key": "dropped.<id>",
|
||||
"value": {
|
||||
"$ref": "#/defs/Drop"
|
||||
},
|
||||
"description": "an ask its caller no longer waits for"
|
||||
},
|
||||
{
|
||||
"key": "capacity.<node>",
|
||||
"value": {
|
||||
@@ -83,6 +108,25 @@
|
||||
],
|
||||
"description": "the toolchains the nodes report",
|
||||
"history": 1
|
||||
},
|
||||
{
|
||||
"name": "detected-steps",
|
||||
"template": "state",
|
||||
"history": 1,
|
||||
"description": "each artifact's detected steps, one key per artifact (design 47 G section 326, section 414)",
|
||||
"key-forms": [
|
||||
{
|
||||
"key": "<module>.<artifact>",
|
||||
"value": {
|
||||
"$ref": "#/defs/DetectedSteps"
|
||||
},
|
||||
"description": "an artifact's detected steps"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
],
|
||||
"family": {
|
||||
"name": "node-build-image.events",
|
||||
"max-age-days": 7
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,24 +7,49 @@
|
||||
"decision": "novox/hq ADR 0525, ADR 0536, ADR 0553",
|
||||
"pulled-by-kind": true,
|
||||
"yields": true,
|
||||
"acts": [
|
||||
{
|
||||
"step": "build",
|
||||
"on": "typescript",
|
||||
"bound": "60m"
|
||||
}
|
||||
],
|
||||
"accepts": [
|
||||
{
|
||||
"name": "delivery",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
}
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-builds"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "check",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
}
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-delivery-checker"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "step",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-pipeline-runner"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "recheck",
|
||||
"body": {
|
||||
"$ref": "#/defs/StepAsk"
|
||||
}
|
||||
},
|
||||
"callers": [
|
||||
"seat:mesh-delivery-checker"
|
||||
]
|
||||
}
|
||||
],
|
||||
"description": "The Node build module on a node: it takes the asks of the builder and the checker, runs them as steps and answers.",
|
||||
@@ -58,6 +83,13 @@
|
||||
},
|
||||
"description": "whether a node is paused"
|
||||
},
|
||||
{
|
||||
"key": "dropped.<id>",
|
||||
"value": {
|
||||
"$ref": "#/defs/Drop"
|
||||
},
|
||||
"description": "an ask its caller no longer waits for"
|
||||
},
|
||||
{
|
||||
"key": "capacity.<node>",
|
||||
"value": {
|
||||
@@ -83,6 +115,25 @@
|
||||
],
|
||||
"description": "the toolchains the nodes report",
|
||||
"history": 1
|
||||
},
|
||||
{
|
||||
"name": "detected-steps",
|
||||
"template": "state",
|
||||
"history": 1,
|
||||
"description": "each artifact's detected steps, one key per artifact (design 47 G section 326, section 414)",
|
||||
"key-forms": [
|
||||
{
|
||||
"key": "<module>.<artifact>",
|
||||
"value": {
|
||||
"$ref": "#/defs/DetectedSteps"
|
||||
},
|
||||
"description": "an artifact's detected steps"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
],
|
||||
"family": {
|
||||
"name": "node-build-node.events",
|
||||
"max-age-days": 7
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,8 +5,14 @@
|
||||
"grain": "whole",
|
||||
"domain": "Core",
|
||||
"decision": "novox/hq ADR 0563",
|
||||
"description": "The node seat every node's engine holds (novox/hq ADR 0563, ADR 0618 §3, §4): its hand acts on the operator's warrant, its read-only judgements, its compositions and what it reads of a manifest. Each verb is answered on this node's subject, mesh.seat.node-engine.tool.<verb>.<node>, and each event is published on mesh.seat.node-engine.event.<event>.<node>, the node's name its last token.",
|
||||
"description": "The node seat every node's engine holds (novox/hq ADR 0563, ADR 0618 §3, §4): its hand acts on the operator's warrant, its read-only judgements, its compositions and what it reads of a manifest. Each verb is answered on this node's subject, mesh.seat.node-engine.tool.<verb>.<node>, and each event is published on mesh.seat.node-engine.event.<event>.<node>, the node's name its last token, or, for an event whose subject names <node>, there (composed.<node>, running.<node>.<module>): the grants part grants a node's account only its own node's subjects (ADR 0363 §2).",
|
||||
"held-by-the-engine": true,
|
||||
"acts": [
|
||||
{
|
||||
"step": "compose",
|
||||
"on": "every"
|
||||
}
|
||||
],
|
||||
"verbs": [
|
||||
{
|
||||
"name": "hand-over",
|
||||
@@ -29,7 +35,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Asked"
|
||||
}
|
||||
},
|
||||
"class": "warrant"
|
||||
},
|
||||
{
|
||||
"name": "access-act",
|
||||
@@ -57,7 +64,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Asked"
|
||||
}
|
||||
},
|
||||
"class": "warrant"
|
||||
},
|
||||
{
|
||||
"name": "judge-directories",
|
||||
@@ -68,7 +76,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Said"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "setuid-search",
|
||||
@@ -84,7 +93,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Said"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "root-free",
|
||||
@@ -107,7 +117,8 @@
|
||||
"required": [
|
||||
"machines"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "acts",
|
||||
@@ -127,7 +138,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Acts"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "packages",
|
||||
@@ -217,7 +229,8 @@
|
||||
"node",
|
||||
"source"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "composition",
|
||||
@@ -491,7 +504,8 @@
|
||||
"composition",
|
||||
"judged"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "compose",
|
||||
@@ -554,7 +568,8 @@
|
||||
"required": [
|
||||
"pass"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "compose-candidate",
|
||||
@@ -633,7 +648,8 @@
|
||||
"own",
|
||||
"took"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "manifest-reads",
|
||||
@@ -673,12 +689,17 @@
|
||||
"stated-at"
|
||||
],
|
||||
"description": "what this machine's engine reads of a manifest (ADR 0618 §3)"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "seat-list",
|
||||
"description": "The seat list this engine holds and what it waits for (novox/hq ADR 0636 §7): each seat's source (trunk or bootstrap) and digest, the seats held from the bootstrap alone, the definitions refused, the last error and whether the seat mesh-catalog has answered. Read-only.",
|
||||
"callers": "the operator and the healers",
|
||||
"callers": [
|
||||
"persons",
|
||||
"sessions",
|
||||
"healers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {}
|
||||
@@ -690,7 +711,11 @@
|
||||
{
|
||||
"name": "seat-list-again",
|
||||
"description": "Make this engine read the seat list from the seat mesh-catalog now (novox/hq ADR 0636 §7), the recovery of a list unread; it answers what it holds afterwards, and the error when the read failed. A read that changed nothing still ends the engine's wait.",
|
||||
"callers": "the operator and the healers",
|
||||
"callers": [
|
||||
"persons",
|
||||
"sessions",
|
||||
"healers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {}
|
||||
@@ -698,6 +723,29 @@
|
||||
"answer": {
|
||||
"$ref": "#/defs/SeatList"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "process-builds",
|
||||
"description": "The build each process on this node was started with (design 47 *The revision view*): per service and container the fingerprint the node-engine handed it in MESH_FINGERPRINT, or why it is unknown, and when it started. Narrowed by module. Reads only.",
|
||||
"callers": [
|
||||
"persons",
|
||||
"sessions",
|
||||
"healers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "only this module's processes"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/ProcessBuilds"
|
||||
},
|
||||
"class": "read"
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
@@ -728,6 +776,31 @@
|
||||
"body": {
|
||||
"$ref": "#/defs/ManifestReadsChanged"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "composed",
|
||||
"subject": "composed.<node>",
|
||||
"body": {
|
||||
"$ref": "#/defs/Composed"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "running",
|
||||
"subject": "running.<node>.<module>",
|
||||
"keep": {
|
||||
"max-age-days": 0,
|
||||
"last-per-subject": true
|
||||
},
|
||||
"body": {
|
||||
"$ref": "#/defs/Running"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "capabilities-changed",
|
||||
"subject": "capabilities-changed.<node>",
|
||||
"body": {
|
||||
"$ref": "#/defs/CapabilitiesChanged"
|
||||
}
|
||||
}
|
||||
],
|
||||
"family": {
|
||||
@@ -2658,6 +2731,183 @@
|
||||
"state",
|
||||
"since"
|
||||
]
|
||||
},
|
||||
"Composed": {
|
||||
"type": "object",
|
||||
"description": "an entry composed on a node (design 47 *What each step says*)",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint of the want composed"
|
||||
},
|
||||
"digest": {
|
||||
"type": "string",
|
||||
"description": "the digest of the composition (design 47 G 404)"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when, RFC 3339",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"node",
|
||||
"module",
|
||||
"fingerprint",
|
||||
"digest",
|
||||
"at"
|
||||
]
|
||||
},
|
||||
"Running": {
|
||||
"type": "object",
|
||||
"description": "a module running healthy on a node at a build: what the node-engines of other nodes and the grants part decide a seat's pass from (ADR 0660 §2), kept last per subject with no age limit",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint of the build it runs; none with stopped"
|
||||
},
|
||||
"manifest": {
|
||||
"type": "string",
|
||||
"description": "the digest of that build's manifest, the indexer's manifest of it, read by digest from the catalog half"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when it was seen running healthy, RFC 3339",
|
||||
"format": "date-time"
|
||||
},
|
||||
"stopped": {
|
||||
"type": "boolean",
|
||||
"description": "true when the module no longer runs on the node: no fingerprint or manifest then (design 47 G 365, 404); mesh-sdk's SeatsToPassOn counts such a module as not running there"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"node",
|
||||
"module",
|
||||
"at"
|
||||
]
|
||||
},
|
||||
"CapabilitiesChanged": {
|
||||
"type": "object",
|
||||
"description": "a node's capabilities changed, which the assigner places by",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node"
|
||||
},
|
||||
"capabilities": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "its capabilities now"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when, RFC 3339",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"node",
|
||||
"capabilities",
|
||||
"at"
|
||||
]
|
||||
},
|
||||
"ProcessBuild": {
|
||||
"type": "object",
|
||||
"description": "the build one process of a module was started with",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"process": {
|
||||
"type": "string",
|
||||
"description": "the service's unit or the container's name"
|
||||
},
|
||||
"kind": {
|
||||
"type": "string",
|
||||
"description": "service or container",
|
||||
"enum": [
|
||||
"service",
|
||||
"container"
|
||||
]
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint handed to it in MESH_FINGERPRINT; empty when it was started without one"
|
||||
},
|
||||
"unknown": {
|
||||
"type": "string",
|
||||
"description": "why its build is unknown: started before the node-engine handed MESH_FINGERPRINT, or the value could not be read"
|
||||
},
|
||||
"started": {
|
||||
"type": "string",
|
||||
"description": "when it was started, RFC 3339",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"process",
|
||||
"kind"
|
||||
]
|
||||
},
|
||||
"ProcessBuilds": {
|
||||
"type": "object",
|
||||
"description": "what process-builds answers",
|
||||
"properties": {
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node"
|
||||
},
|
||||
"processes": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/ProcessBuild"
|
||||
},
|
||||
"description": "every process the node-engine started, by module"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why they could not be read"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"node",
|
||||
"processes"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
"name": "execute",
|
||||
"description": "Run one command on this machine as the operator account, in a non-interactive login shell in its home; answers with what it printed and how it exited.",
|
||||
"optional": true,
|
||||
"needs-approval": true,
|
||||
"input": {
|
||||
"properties": {
|
||||
"command": {
|
||||
|
||||
@@ -12,8 +12,10 @@
|
||||
"verbs": [
|
||||
{
|
||||
"name": "hold",
|
||||
"description": "Keep one untagged bundle, archive or copied base from removal by retention, as the artifact sweep's rules keep it (ADR 0617 §2); never an image of the holder's own. Emits held.",
|
||||
"callers": "the module that runs the artifact sweep alone",
|
||||
"description": "Keep one untagged bundle, archive or copied base from removal by retention, as the artifact sweep's rules keep it (ADR 0617 \u00a72); never an image of the holder's own. Emits held.",
|
||||
"callers": [
|
||||
"seat:mesh-artifact-sweep"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -57,7 +59,9 @@
|
||||
{
|
||||
"name": "release",
|
||||
"description": "Let a hold go; emits released. A release of what is not held answers released false and emits nothing, never an error: the outcome asked holds already. By hand only through the holder's own tool, the operator's session as the proved caller, recorded as a hand act.",
|
||||
"callers": "the module that runs the artifact sweep; the operator's session through the holder's tool",
|
||||
"callers": [
|
||||
"seat:mesh-artifact-sweep"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -96,8 +100,10 @@
|
||||
},
|
||||
{
|
||||
"name": "list",
|
||||
"description": "What the store holds of one repository, or of every repository the seat holds when none is named: every manifest keeping one bundle or archive, each with its digest, whether it is an index (and the manifests an index names), the tags naming it, its size and whether it is held. Read from the store itself, so a manifest no tag names is listed too; it reads only (ADR 0632 §3).",
|
||||
"callers": "any caller whose role grants it",
|
||||
"description": "What the store holds of one repository, or of every repository the seat holds when none is named: every manifest keeping one bundle or archive, each with its digest, whether it is an index (and the manifests an index names), the tags naming it, its size and whether it is held. Read from the store itself, so a manifest no tag names is listed too; it reads only (ADR 0632 \u00a73).",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
||||
@@ -126,7 +126,7 @@
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "open (open and held), ended or all; none is open when no key or since is given, else all"
|
||||
"description": "open (open, held and held-back), ended or all; none is open when no key or since is given, else all"
|
||||
},
|
||||
"since": {
|
||||
"type": "string",
|
||||
@@ -154,7 +154,11 @@
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "how the ask stands: open, held, or how it ended (answered, expired, cancelled)"
|
||||
"description": "how the ask stands: open, held (no ready channel), held-back (kept open behind the asker's newer asks, ADR 0666 §12), or how it ended (answered, expired, cancelled)"
|
||||
},
|
||||
"held-since": {
|
||||
"type": "string",
|
||||
"description": "when the ask was held back, RFC 3339; present while its state is held-back"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -176,6 +180,41 @@
|
||||
"asks"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ask-again",
|
||||
"description": "Offer a held-back ask now, on a channel that is ready: the asker's ask kept open behind its newer asks (design 47 G 83, 394).",
|
||||
"class": "act",
|
||||
"callers": [
|
||||
"operator",
|
||||
"healers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"key": {
|
||||
"type": "string",
|
||||
"description": "<asker>.<id> of the held-back ask"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"key"
|
||||
],
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "where the ask stands after it was offered",
|
||||
"properties": {
|
||||
"state": {
|
||||
"type": "string"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it was not offered; set alone"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"accepts": [
|
||||
@@ -248,7 +287,7 @@
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "how it stands: open, chosen, expired, cancelled, replaced or refused"
|
||||
"description": "how it stands: open, held-back (kept open behind the asker's newer asks, ADR 0666 §12), chosen, expired, cancelled, replaced or refused"
|
||||
},
|
||||
"opened": {
|
||||
"type": "string",
|
||||
@@ -269,6 +308,10 @@
|
||||
"type": "boolean",
|
||||
"description": "its asker has been told how it ended"
|
||||
},
|
||||
"held-since": {
|
||||
"type": "string",
|
||||
"description": "when the ask was held back, RFC 3339; present while its state is held-back"
|
||||
},
|
||||
"answer": {
|
||||
"type": "string",
|
||||
"description": "how it ended, in words"
|
||||
|
||||
Vendored
+2
-3
@@ -11,9 +11,8 @@ Only what go/catalogue's tests read is captured (R4b, issue 1379). Refreshed 202
|
||||
repositories; before that it was mesh-controller's copy, which still held two modules that had left the catalogue.
|
||||
|
||||
mesh-catalog b5dbfbb784507e211372a7c9640d91f7d6dadd84 modules/*/module.json, modules/*/files/**, modules/*/templates/**, predefined.json
|
||||
mesh-contracts 70fe186d7f5743e61f3ce2bbd97a8bfabc5b596e the seat files of the eight bootstrapped seats held there (seats/, health-and-repair/seats/, operator-and-conversation/seats/), as seat.json.captured
|
||||
mesh-contracts bb16f99e2d5e854bb8f6552ce4b256e7c10e8ea0 of those, health-and-repair/seats/mesh-watchdogs and operator-and-conversation/seats/operator-channel (issue 1966)
|
||||
mesh-delivery 932e7ccf025513ec4fce38a534c2c38defbc6701 contracts/seats/mesh-catalog and mesh-delivery-checker, as seat.json.captured (go/seatlist's bootstrap test)
|
||||
mesh-contracts 5f7610f521bdb65ef72728022049d015e27ee93b the seat files of the eight bootstrapped seats held there (seats/, health-and-repair/seats/, operator-and-conversation/seats/), as seat.json.captured (milestone 47/G)
|
||||
mesh-delivery c77e747f4e0cb829128c2fa7e80bf959c0af98c8 contracts/seats/mesh-catalog and mesh-delivery-checker, as seat.json.captured (go/seatlist's bootstrap test; milestone 47/G)
|
||||
mesh-host cdcba9ca73755854d21e4e657d7e46c32b9b5265 internal/apply/placement_guard.go
|
||||
|
||||
The two seat copies are put back the same way (git show <commit>:<file> > <file>.captured, the path kept). To move the others, from this repository's go/ directory, with the two repositories checked out beside mesh-sdk:
|
||||
|
||||
Vendored
+304
-5
@@ -84,15 +84,26 @@
|
||||
},
|
||||
{
|
||||
"name": "resync",
|
||||
"description": "Read every observer's findings again and raise and clear what differs from the open conditions: the recovery of a keeper that missed a change.",
|
||||
"description": "Ask the observers to state their findings again, every one or the one named, and raise and clear what differs from the open conditions: the recovery of a keeper that missed a change. Each call is written in the hand-act log of the seat mesh-hand-acts (design 47 G 390).",
|
||||
"input": {
|
||||
"properties": {},
|
||||
"type": "object"
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "ask this observer alone; none asks all"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "what was raised and cleared again"
|
||||
}
|
||||
},
|
||||
"callers": [
|
||||
"operator",
|
||||
"healers",
|
||||
"sessions"
|
||||
]
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
@@ -113,6 +124,40 @@
|
||||
"body": {
|
||||
"$ref": "#/defs/ConditionEvent"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "findings-asked",
|
||||
"keep": {
|
||||
"max-age-days": 7,
|
||||
"max-mib": 16
|
||||
},
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "the keeper asks every observer, or one, to state its findings (design 47 G 384, 390)",
|
||||
"properties": {
|
||||
"ask": {
|
||||
"type": "string",
|
||||
"description": "the ask's id"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"by": {
|
||||
"type": "string",
|
||||
"description": "who asked: the keeper, or the person or session that called resync"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "to ask one observer; none asks all"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"ask",
|
||||
"at",
|
||||
"by"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"family": {
|
||||
@@ -363,6 +408,14 @@
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"owner": {
|
||||
"type": "string",
|
||||
"description": "the module the finding is about, when not the observer"
|
||||
},
|
||||
"waiting-on": {
|
||||
"type": "string",
|
||||
"description": "what it waits on: a person, a part or a call"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -380,7 +433,67 @@
|
||||
"description": "one finding of the observer that wrote it"
|
||||
}
|
||||
],
|
||||
"description": "every observer's findings, one key per finding; a key written raises or changes the condition of the same key, a key deleted clears it"
|
||||
"description": "every observer's findings, one key per finding, kept in the observer's own state and read only by its owner's read tool; the keeper hears each change as the observer's events finding-written, finding-cleared and findings-stated (design 47 G 383, 434)"
|
||||
},
|
||||
{
|
||||
"name": "findings-views",
|
||||
"template": "state",
|
||||
"description": "the keeper's sources: one key per observer and node, its last stated set with its at, its pending keys and the open asks; deleted when the module leaves the catalog or the node (design 47 G 388)",
|
||||
"key-forms": [
|
||||
{
|
||||
"key": "<observer>.<node>",
|
||||
"description": "one observer on one node",
|
||||
"value": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer"
|
||||
},
|
||||
"observer": {
|
||||
"type": "string"
|
||||
},
|
||||
"node": {
|
||||
"type": "string"
|
||||
},
|
||||
"stated": {
|
||||
"type": "object",
|
||||
"description": "the last findings-stated set",
|
||||
"properties": {
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"findings": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/bodies/Finding"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"pending": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "the keys it cannot judge yet"
|
||||
},
|
||||
"asks": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "the open asks"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"observer",
|
||||
"node"
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"defs": {
|
||||
@@ -643,5 +756,191 @@
|
||||
"change"
|
||||
]
|
||||
}
|
||||
},
|
||||
"bodies": {
|
||||
"Finding": {
|
||||
"type": "object",
|
||||
"description": "one finding as an observer says it: the layout whole, plus scope, id and since (design 47 G 437, 439)",
|
||||
"properties": {
|
||||
"kind": {
|
||||
"type": "string"
|
||||
},
|
||||
"scope": {
|
||||
"type": "string",
|
||||
"description": "the key's first part: <scope>.<id>.<kind> (ADR 0564)"
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the key's second part"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"since": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "since when the finding stands"
|
||||
},
|
||||
"severity": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"urgent",
|
||||
"warning"
|
||||
]
|
||||
},
|
||||
"summary": {
|
||||
"type": "string",
|
||||
"description": "one line"
|
||||
},
|
||||
"headline": {
|
||||
"type": "string"
|
||||
},
|
||||
"explanation": {
|
||||
"type": "string"
|
||||
},
|
||||
"subject": {
|
||||
"$ref": "#/defs/Subject"
|
||||
},
|
||||
"evidence": {
|
||||
"type": "array",
|
||||
"description": "newest first, at most 10",
|
||||
"items": {
|
||||
"$ref": "#/defs/Evidence"
|
||||
}
|
||||
},
|
||||
"source": {
|
||||
"type": "string",
|
||||
"description": "the row, probe or event that saw it"
|
||||
},
|
||||
"observer": {
|
||||
"type": "string",
|
||||
"description": "the module that wrote it"
|
||||
},
|
||||
"owner": {
|
||||
"type": "string",
|
||||
"description": "the module the finding is about, when not the observer"
|
||||
},
|
||||
"waiting-on": {
|
||||
"type": "string",
|
||||
"description": "what it waits on: a person, a part or a call"
|
||||
},
|
||||
"actions": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/Action"
|
||||
}
|
||||
},
|
||||
"needs": {
|
||||
"type": "string"
|
||||
},
|
||||
"resolver": {
|
||||
"type": "string",
|
||||
"description": "self, operator, agent or healer:<name>"
|
||||
},
|
||||
"ref": {
|
||||
"type": "string",
|
||||
"description": "the key's last part when it is not the kind"
|
||||
},
|
||||
"run": {
|
||||
"type": "string",
|
||||
"description": "what of its own saw it last"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"kind",
|
||||
"scope",
|
||||
"id",
|
||||
"at",
|
||||
"since",
|
||||
"severity",
|
||||
"summary",
|
||||
"subject",
|
||||
"source",
|
||||
"observer"
|
||||
]
|
||||
},
|
||||
"FindingWritten": {
|
||||
"$ref": "#/bodies/Finding"
|
||||
},
|
||||
"FindingCleared": {
|
||||
"type": "object",
|
||||
"description": "an observer no longer observes a finding",
|
||||
"properties": {
|
||||
"kind": {
|
||||
"type": "string"
|
||||
},
|
||||
"scope": {
|
||||
"type": "string"
|
||||
},
|
||||
"id": {
|
||||
"type": "string"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"why": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"kind",
|
||||
"scope",
|
||||
"id",
|
||||
"at",
|
||||
"why"
|
||||
]
|
||||
},
|
||||
"FindingsStated": {
|
||||
"type": "object",
|
||||
"description": "every finding an observer observes now, at its start and when asked (design 47 G 384, 439)",
|
||||
"properties": {
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"asked": {
|
||||
"type": "string",
|
||||
"description": "the ask it answers; none at a start"
|
||||
},
|
||||
"findings": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/bodies/Finding"
|
||||
}
|
||||
},
|
||||
"pending": {
|
||||
"type": "array",
|
||||
"description": "the keys the observer cannot judge yet since its start, with their since and bound",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"key": {
|
||||
"type": "string"
|
||||
},
|
||||
"since": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"bound": {
|
||||
"type": "string",
|
||||
"description": "a duration such as 5m"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"key",
|
||||
"since",
|
||||
"bound"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"at",
|
||||
"findings",
|
||||
"pending"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Vendored
+80
@@ -159,6 +159,86 @@
|
||||
}
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
{
|
||||
"name": "machine-away",
|
||||
"subject": "machine-away.<machine>",
|
||||
"keep": {
|
||||
"max-age-days": 90,
|
||||
"max-mib": 16
|
||||
},
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "the watchman's presence key of a machine expired (ADR 0564 4); published by the holder of this seat alone for another machine (design 47 G 436)",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"machine": {
|
||||
"type": "string",
|
||||
"description": "the machine whose presence changed"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"last-heard": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when the machine was last heard"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"machine",
|
||||
"at",
|
||||
"last-heard"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "machine-back",
|
||||
"subject": "machine-back.<machine>",
|
||||
"keep": {
|
||||
"max-age-days": 90,
|
||||
"max-mib": 16
|
||||
},
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a machine is heard again after it was away",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"machine": {
|
||||
"type": "string",
|
||||
"description": "the machine whose presence changed"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"last-heard": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when the machine was last heard"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"machine",
|
||||
"at",
|
||||
"last-heard"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"family": {
|
||||
"name": "mesh-watchdogs.events",
|
||||
"max-age-days": 7
|
||||
},
|
||||
"states": [
|
||||
{
|
||||
"name": "presence",
|
||||
|
||||
+46
-3
@@ -126,7 +126,7 @@
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "open (open and held), ended or all; none is open when no key or since is given, else all"
|
||||
"description": "open (open, held and held-back), ended or all; none is open when no key or since is given, else all"
|
||||
},
|
||||
"since": {
|
||||
"type": "string",
|
||||
@@ -154,7 +154,11 @@
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "how the ask stands: open, held, or how it ended (answered, expired, cancelled)"
|
||||
"description": "how the ask stands: open, held (no ready channel), held-back (kept open behind the asker's newer asks, ADR 0666 §12), or how it ended (answered, expired, cancelled)"
|
||||
},
|
||||
"held-since": {
|
||||
"type": "string",
|
||||
"description": "when the ask was held back, RFC 3339; present while its state is held-back"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -176,6 +180,41 @@
|
||||
"asks"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ask-again",
|
||||
"description": "Offer a held-back ask now, on a channel that is ready: the asker's ask kept open behind its newer asks (design 47 G 83, 394).",
|
||||
"class": "act",
|
||||
"callers": [
|
||||
"operator",
|
||||
"healers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"key": {
|
||||
"type": "string",
|
||||
"description": "<asker>.<id> of the held-back ask"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"key"
|
||||
],
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"description": "where the ask stands after it was offered",
|
||||
"properties": {
|
||||
"state": {
|
||||
"type": "string"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it was not offered; set alone"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"accepts": [
|
||||
@@ -248,7 +287,7 @@
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "how it stands: open, chosen, expired, cancelled, replaced or refused"
|
||||
"description": "how it stands: open, held-back (kept open behind the asker's newer asks, ADR 0666 §12), chosen, expired, cancelled, replaced or refused"
|
||||
},
|
||||
"opened": {
|
||||
"type": "string",
|
||||
@@ -269,6 +308,10 @@
|
||||
"type": "boolean",
|
||||
"description": "its asker has been told how it ended"
|
||||
},
|
||||
"held-since": {
|
||||
"type": "string",
|
||||
"description": "when the ask was held back, RFC 3339; present while its state is held-back"
|
||||
},
|
||||
"answer": {
|
||||
"type": "string",
|
||||
"description": "how it ended, in words"
|
||||
|
||||
@@ -11,7 +11,9 @@
|
||||
{
|
||||
"name": "list",
|
||||
"description": "Every entry the bus module created, its template, its settings and its fill against its cap.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -41,7 +43,9 @@
|
||||
{
|
||||
"name": "show",
|
||||
"description": "One entry, its template, settings and fill.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Named"
|
||||
},
|
||||
@@ -53,7 +57,9 @@
|
||||
{
|
||||
"name": "check",
|
||||
"description": "Compare what the bus holds with what was asked, entry by entry; a difference that only grows is said as such.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -109,7 +115,9 @@
|
||||
{
|
||||
"name": "orphans",
|
||||
"description": "Entries the bus holds that no manifest asks for; never one whose manifest the judge refused or outgrew, nor one of the foundation's old sections.",
|
||||
"callers": "any caller whose role grants it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {},
|
||||
@@ -135,43 +143,54 @@
|
||||
{
|
||||
"name": "create",
|
||||
"description": "Create one entry now.",
|
||||
"callers": "the bus module's own process only",
|
||||
"callers": [
|
||||
"module:nats"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Entry"
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Held"
|
||||
},
|
||||
"optional": true
|
||||
"optional": true,
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "apply",
|
||||
"description": "Apply a difference that only grows: a larger cap, a longer age.",
|
||||
"callers": "the bus module's own process only",
|
||||
"callers": [
|
||||
"module:nats"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Named"
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Held"
|
||||
},
|
||||
"optional": true
|
||||
"optional": true,
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "recreate",
|
||||
"description": "Rebuild an entry whose settings differ in a way that cannot grow, from its data where the storage type allows, after a stream snapshot.",
|
||||
"callers": "the bus module's process, on the operator's warrant",
|
||||
"callers": [
|
||||
"module:nats"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Warranted"
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Held"
|
||||
},
|
||||
"optional": true
|
||||
"optional": true,
|
||||
"class": "warrant"
|
||||
},
|
||||
{
|
||||
"name": "drop",
|
||||
"description": "Remove one orphan, after a stream snapshot.",
|
||||
"callers": "the bus module's process, on the operator's warrant",
|
||||
"callers": [
|
||||
"module:nats"
|
||||
],
|
||||
"input": {
|
||||
"$ref": "#/defs/Warranted"
|
||||
},
|
||||
@@ -191,7 +210,152 @@
|
||||
"dropped"
|
||||
]
|
||||
},
|
||||
"optional": true
|
||||
"optional": true,
|
||||
"class": "warrant"
|
||||
},
|
||||
{
|
||||
"name": "snapshot-kept",
|
||||
"description": "Take the restore point of one module's kept data on the bus: the data whole and the position of each durable consumer the module reads with, keyed by the module, the kept data, its form and the fingerprint it is taken before (design 47 *A module's kept data on the bus*).",
|
||||
"callers": [
|
||||
"holder:node-backup@same-node"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module",
|
||||
"minLength": 1
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data, its local name in the module's manifest",
|
||||
"minLength": 1
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form, the number the holder raises when it changes how it writes it (0 when undeclared)"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint the restore point is taken before",
|
||||
"minLength": 1
|
||||
},
|
||||
"why": {
|
||||
"type": "string",
|
||||
"description": "why it is taken"
|
||||
},
|
||||
"catch-up": {
|
||||
"type": "object",
|
||||
"description": "the catch-up tool the newer manifest declares beside the kept data and its arguments whole, recorded in the restore point (design 47 G 299, 406)",
|
||||
"properties": {
|
||||
"tool": {
|
||||
"type": "string"
|
||||
},
|
||||
"arguments": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"tool"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint"
|
||||
],
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"point": {
|
||||
"$ref": "#/defs/KeptPoint"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed; set alone"
|
||||
}
|
||||
},
|
||||
"description": "the restore point taken, or the error"
|
||||
},
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "restore-kept",
|
||||
"description": "Restore one module's kept data from its restore point beside the live data, never over it: the live data is set aside under a name of its own and the consumers' positions are set back with it. With aside-only it sets the live data aside and restores nothing; with discard-aside, naming data set aside, it removes that data and restores nothing (design 47 G 405).",
|
||||
"callers": [
|
||||
"holder:node-backup@same-node"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module",
|
||||
"minLength": 1
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data, its local name in the module's manifest",
|
||||
"minLength": 1
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form, the number the holder raises when it changes how it writes it (0 when undeclared)"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint the restore point is taken before",
|
||||
"minLength": 1
|
||||
},
|
||||
"snapshot": {
|
||||
"type": "string",
|
||||
"description": "the restore point's name; not with aside-only or discard-aside",
|
||||
"minLength": 1
|
||||
},
|
||||
"why": {
|
||||
"type": "string",
|
||||
"description": "why"
|
||||
},
|
||||
"aside-only": {
|
||||
"type": "boolean",
|
||||
"description": "set the live data aside and restore nothing"
|
||||
},
|
||||
"discard-aside": {
|
||||
"type": "string",
|
||||
"description": "the name of data set aside: remove it and restore nothing"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint"
|
||||
],
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"restored": {
|
||||
"type": "boolean",
|
||||
"description": "the restore point is the live data now"
|
||||
},
|
||||
"aside": {
|
||||
"$ref": "#/defs/Aside"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed; set alone"
|
||||
}
|
||||
},
|
||||
"description": "what was restored and what was set aside, or the error"
|
||||
},
|
||||
"class": "act"
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
@@ -558,6 +722,10 @@
|
||||
"type": "string"
|
||||
},
|
||||
"description": "its subjects, for a stream"
|
||||
},
|
||||
"objects": {
|
||||
"type": "string",
|
||||
"description": "the bus name of the state's <state>-objects, where its large values go (design 47 G 58, 399)"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -565,6 +733,133 @@
|
||||
"storage-type"
|
||||
],
|
||||
"description": "the binding a module receives in its membership for one entry (ADR 0595 §1, §7)"
|
||||
},
|
||||
"KeptPoint": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module",
|
||||
"minLength": 1
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data, its local name in the module's manifest",
|
||||
"minLength": 1
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form, the number the holder raises when it changes how it writes it (0 when undeclared)"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint the restore point is taken before",
|
||||
"minLength": 1
|
||||
},
|
||||
"snapshot": {
|
||||
"type": "string",
|
||||
"description": "the restore point's name"
|
||||
},
|
||||
"consumers": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"stream": {
|
||||
"type": "string",
|
||||
"description": "the stream"
|
||||
},
|
||||
"consumer": {
|
||||
"type": "string",
|
||||
"description": "the durable consumer"
|
||||
},
|
||||
"sequence": {
|
||||
"type": "integer",
|
||||
"description": "its acknowledged position"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"stream",
|
||||
"consumer",
|
||||
"sequence"
|
||||
]
|
||||
},
|
||||
"description": "each durable consumer the module reads with, and its position"
|
||||
},
|
||||
"size": {
|
||||
"type": "integer",
|
||||
"description": "its size in bytes"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when it was taken",
|
||||
"format": "date-time"
|
||||
},
|
||||
"catch-up": {
|
||||
"type": "object",
|
||||
"description": "the catch-up tool and its arguments the restore point records (design 47 G 406)",
|
||||
"properties": {
|
||||
"tool": {
|
||||
"type": "string"
|
||||
},
|
||||
"arguments": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"tool"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint",
|
||||
"snapshot"
|
||||
],
|
||||
"description": "a restore point of one module's kept data on the bus, whole, with its consumers' positions"
|
||||
},
|
||||
"Aside": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "its id, for discard-aside"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "the form it held"
|
||||
},
|
||||
"name": {
|
||||
"type": "string",
|
||||
"description": "the name it is kept under on the bus"
|
||||
},
|
||||
"size": {
|
||||
"type": "integer",
|
||||
"description": "its size in bytes"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when it was set aside",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"module",
|
||||
"kept",
|
||||
"name"
|
||||
],
|
||||
"description": "live kept data a restore set aside, never removed but by discard-aside"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -64,7 +64,9 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"callers": "any caller whose role grants it; the checker asks it",
|
||||
"callers": [
|
||||
"invokers"
|
||||
],
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
"verbs": [
|
||||
{
|
||||
"name": "backed-up",
|
||||
"description": "What this machine backs up: each module, what it declared, its last good night, how many restore points are kept and the repository's size.",
|
||||
"description": "What this machine backs up: each module, what it declared, its last good night, how many restore points are kept and the repository's size. Also each module's restore points of its kept data on the bus (the kept data, the form, the fingerprint each was taken before) and the data set aside at each restore, with its size.",
|
||||
"replaces": [
|
||||
"restic snapshots"
|
||||
],
|
||||
@@ -24,7 +24,7 @@
|
||||
},
|
||||
{
|
||||
"name": "now",
|
||||
"description": "Take a backup now, of one module or of every module on this machine — before a migration, a retirement or anything else that could go wrong.",
|
||||
"description": "Take a backup now, of one module or of every module on this machine — before a migration, a retirement or anything else that could go wrong. With kept, a restore point of one kept data on the bus instead, said by the event ended.",
|
||||
"replaces": [
|
||||
"restic backup"
|
||||
],
|
||||
@@ -33,14 +33,42 @@
|
||||
"module": {
|
||||
"description": "one module (optional)",
|
||||
"type": "string"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "one kept data of the module on the bus, its local name: its restore point is taken by the bus module's account, of the node holding mesh-broker"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "with kept: its form now"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "with kept: the fingerprint the restore point is taken before"
|
||||
},
|
||||
"catch-up": {
|
||||
"type": "object",
|
||||
"description": "with kept: the catch-up tool the newer manifest declares beside it and its arguments whole, recorded in the restore point (design 47 G 299, 406)",
|
||||
"properties": {
|
||||
"tool": {
|
||||
"type": "string"
|
||||
},
|
||||
"arguments": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"tool"
|
||||
]
|
||||
}
|
||||
},
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "restore",
|
||||
"description": "Restore one module's data from a restore point BESIDE the live data, never over it: each directory as \u003cpath\u003e.restored-\u003cdate\u003e. Swapping it in is a person's act. Lists the restore points when none is named.",
|
||||
"description": "Restore one module's data from a restore point BESIDE the live data, never over it: each directory as <path>.restored-<date>. Swapping it in is a person's act. Lists the restore points when none is named. With kept, the restore point of one kept data on the bus by its module, kept data and form, the live data set aside and never removed, said by the event restored.",
|
||||
"replaces": [
|
||||
"restic restore"
|
||||
],
|
||||
@@ -57,13 +85,96 @@
|
||||
"snapshot": {
|
||||
"description": "the restore point (from `backed-up`; the newest when omitted)",
|
||||
"type": "string"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "one kept data of the module on the bus, its local name: its restore point is taken by the bus module's account, of the node holding mesh-broker"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "with kept: its form now"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "with kept: the fingerprint the restore point is taken before"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module"
|
||||
],
|
||||
"type": "object"
|
||||
},
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "aside",
|
||||
"description": "Set one module's live kept data on the bus aside under a name of its own and restore nothing, after the node agent stopped the newer build (design 47 G 297, 405); the data set aside is listed by backed-up and removed only by discard-aside.",
|
||||
"class": "act",
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "one kept data of the module on the bus, its local name: its restore point is taken by the bus module's account, of the node holding mesh-broker"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "with kept: its form now"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "with kept: the fingerprint the restore point is taken before"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint"
|
||||
]
|
||||
},
|
||||
"answer": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"aside": {
|
||||
"type": "string",
|
||||
"description": "the name the live data is set aside under"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed; set alone"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "discard-aside",
|
||||
"description": "Remove data a restore set aside, on a person's call alone; writes the act, who and why in the hand-act log of the seat mesh-hand-acts.",
|
||||
"callers": [
|
||||
"operator"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the aside's id, as backed-up lists it"
|
||||
},
|
||||
"why": {
|
||||
"type": "string",
|
||||
"description": "why"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"why"
|
||||
]
|
||||
},
|
||||
"class": "act"
|
||||
}
|
||||
],
|
||||
"receives": [
|
||||
@@ -77,5 +188,103 @@
|
||||
"comment": "#",
|
||||
"dirs": true
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
{
|
||||
"name": "ended",
|
||||
"subject": "ended.<node>.<module>.<kept>",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a restore point of a kept data on the bus taken, done or failed",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint"
|
||||
},
|
||||
"outcome": {
|
||||
"enum": [
|
||||
"done",
|
||||
"failed"
|
||||
]
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint",
|
||||
"outcome"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "restored",
|
||||
"subject": "restored.<node>.<module>.<kept>",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a kept data on the bus restored from its restore point beside the live data, done or failed",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"kept": {
|
||||
"type": "string",
|
||||
"description": "the kept data"
|
||||
},
|
||||
"form": {
|
||||
"type": "integer",
|
||||
"description": "its form"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint"
|
||||
},
|
||||
"outcome": {
|
||||
"enum": [
|
||||
"done",
|
||||
"failed"
|
||||
]
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why it failed"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"module",
|
||||
"kept",
|
||||
"form",
|
||||
"fingerprint",
|
||||
"outcome"
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -5,8 +5,14 @@
|
||||
"grain": "whole",
|
||||
"domain": "Core",
|
||||
"decision": "novox/hq ADR 0563",
|
||||
"description": "The node seat every node's engine holds (novox/hq ADR 0563, ADR 0618 §3, §4): its hand acts on the operator's warrant, its read-only judgements, its compositions and what it reads of a manifest. Each verb is answered on this node's subject, mesh.seat.node-engine.tool.<verb>.<node>, and each event is published on mesh.seat.node-engine.event.<event>.<node>, the node's name its last token.",
|
||||
"description": "The node seat every node's engine holds (novox/hq ADR 0563, ADR 0618 §3, §4): its hand acts on the operator's warrant, its read-only judgements, its compositions and what it reads of a manifest. Each verb is answered on this node's subject, mesh.seat.node-engine.tool.<verb>.<node>, and each event is published on mesh.seat.node-engine.event.<event>.<node>, the node's name its last token, or, for an event whose subject names <node>, there (composed.<node>, running.<node>.<module>): the grants part grants a node's account only its own node's subjects (ADR 0363 §2).",
|
||||
"held-by-the-engine": true,
|
||||
"acts": [
|
||||
{
|
||||
"step": "compose",
|
||||
"on": "every"
|
||||
}
|
||||
],
|
||||
"verbs": [
|
||||
{
|
||||
"name": "hand-over",
|
||||
@@ -29,7 +35,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Asked"
|
||||
}
|
||||
},
|
||||
"class": "warrant"
|
||||
},
|
||||
{
|
||||
"name": "access-act",
|
||||
@@ -57,7 +64,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Asked"
|
||||
}
|
||||
},
|
||||
"class": "warrant"
|
||||
},
|
||||
{
|
||||
"name": "judge-directories",
|
||||
@@ -68,7 +76,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Said"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "setuid-search",
|
||||
@@ -84,7 +93,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Said"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "root-free",
|
||||
@@ -107,7 +117,8 @@
|
||||
"required": [
|
||||
"machines"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "acts",
|
||||
@@ -127,7 +138,8 @@
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/Acts"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "packages",
|
||||
@@ -217,7 +229,8 @@
|
||||
"node",
|
||||
"source"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "composition",
|
||||
@@ -491,7 +504,8 @@
|
||||
"composition",
|
||||
"judged"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "compose",
|
||||
@@ -554,7 +568,8 @@
|
||||
"required": [
|
||||
"pass"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "act"
|
||||
},
|
||||
{
|
||||
"name": "compose-candidate",
|
||||
@@ -633,7 +648,8 @@
|
||||
"own",
|
||||
"took"
|
||||
]
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "manifest-reads",
|
||||
@@ -673,12 +689,17 @@
|
||||
"stated-at"
|
||||
],
|
||||
"description": "what this machine's engine reads of a manifest (ADR 0618 §3)"
|
||||
}
|
||||
},
|
||||
"class": "read"
|
||||
},
|
||||
{
|
||||
"name": "seat-list",
|
||||
"description": "The seat list this engine holds and what it waits for (novox/hq ADR 0636 §7): each seat's source (trunk or bootstrap) and digest, the seats held from the bootstrap alone, the definitions refused, the last error and whether the seat mesh-catalog has answered. Read-only.",
|
||||
"callers": "the operator and the healers",
|
||||
"callers": [
|
||||
"persons",
|
||||
"sessions",
|
||||
"healers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {}
|
||||
@@ -690,7 +711,11 @@
|
||||
{
|
||||
"name": "seat-list-again",
|
||||
"description": "Make this engine read the seat list from the seat mesh-catalog now (novox/hq ADR 0636 §7), the recovery of a list unread; it answers what it holds afterwards, and the error when the read failed. A read that changed nothing still ends the engine's wait.",
|
||||
"callers": "the operator and the healers",
|
||||
"callers": [
|
||||
"persons",
|
||||
"sessions",
|
||||
"healers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {}
|
||||
@@ -698,6 +723,29 @@
|
||||
"answer": {
|
||||
"$ref": "#/defs/SeatList"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "process-builds",
|
||||
"description": "The build each process on this node was started with (design 47 *The revision view*): per service and container the fingerprint the node-engine handed it in MESH_FINGERPRINT, or why it is unknown, and when it started. Narrowed by module. Reads only.",
|
||||
"callers": [
|
||||
"persons",
|
||||
"sessions",
|
||||
"healers"
|
||||
],
|
||||
"input": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "only this module's processes"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
},
|
||||
"answer": {
|
||||
"$ref": "#/defs/ProcessBuilds"
|
||||
},
|
||||
"class": "read"
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
@@ -728,6 +776,31 @@
|
||||
"body": {
|
||||
"$ref": "#/defs/ManifestReadsChanged"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "composed",
|
||||
"subject": "composed.<node>",
|
||||
"body": {
|
||||
"$ref": "#/defs/Composed"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "running",
|
||||
"subject": "running.<node>.<module>",
|
||||
"keep": {
|
||||
"max-age-days": 0,
|
||||
"last-per-subject": true
|
||||
},
|
||||
"body": {
|
||||
"$ref": "#/defs/Running"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "capabilities-changed",
|
||||
"subject": "capabilities-changed.<node>",
|
||||
"body": {
|
||||
"$ref": "#/defs/CapabilitiesChanged"
|
||||
}
|
||||
}
|
||||
],
|
||||
"family": {
|
||||
@@ -2658,6 +2731,183 @@
|
||||
"state",
|
||||
"since"
|
||||
]
|
||||
},
|
||||
"Composed": {
|
||||
"type": "object",
|
||||
"description": "an entry composed on a node (design 47 *What each step says*)",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint of the want composed"
|
||||
},
|
||||
"digest": {
|
||||
"type": "string",
|
||||
"description": "the digest of the composition (design 47 G 404)"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when, RFC 3339",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"node",
|
||||
"module",
|
||||
"fingerprint",
|
||||
"digest",
|
||||
"at"
|
||||
]
|
||||
},
|
||||
"Running": {
|
||||
"type": "object",
|
||||
"description": "a module running healthy on a node at a build: what the node-engines of other nodes and the grants part decide a seat's pass from (ADR 0660 §2), kept last per subject with no age limit",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint of the build it runs; none with stopped"
|
||||
},
|
||||
"manifest": {
|
||||
"type": "string",
|
||||
"description": "the digest of that build's manifest, the indexer's manifest of it, read by digest from the catalog half"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when it was seen running healthy, RFC 3339",
|
||||
"format": "date-time"
|
||||
},
|
||||
"stopped": {
|
||||
"type": "boolean",
|
||||
"description": "true when the module no longer runs on the node: no fingerprint or manifest then (design 47 G 365, 404); mesh-sdk's SeatsToPassOn counts such a module as not running there"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"node",
|
||||
"module",
|
||||
"at"
|
||||
]
|
||||
},
|
||||
"CapabilitiesChanged": {
|
||||
"type": "object",
|
||||
"description": "a node's capabilities changed, which the assigner places by",
|
||||
"properties": {
|
||||
"v": {
|
||||
"type": "integer",
|
||||
"description": "the layout's version"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node"
|
||||
},
|
||||
"capabilities": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "its capabilities now"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"description": "when, RFC 3339",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"v",
|
||||
"node",
|
||||
"capabilities",
|
||||
"at"
|
||||
]
|
||||
},
|
||||
"ProcessBuild": {
|
||||
"type": "object",
|
||||
"description": "the build one process of a module was started with",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"process": {
|
||||
"type": "string",
|
||||
"description": "the service's unit or the container's name"
|
||||
},
|
||||
"kind": {
|
||||
"type": "string",
|
||||
"description": "service or container",
|
||||
"enum": [
|
||||
"service",
|
||||
"container"
|
||||
]
|
||||
},
|
||||
"fingerprint": {
|
||||
"type": "string",
|
||||
"description": "the fingerprint handed to it in MESH_FINGERPRINT; empty when it was started without one"
|
||||
},
|
||||
"unknown": {
|
||||
"type": "string",
|
||||
"description": "why its build is unknown: started before the node-engine handed MESH_FINGERPRINT, or the value could not be read"
|
||||
},
|
||||
"started": {
|
||||
"type": "string",
|
||||
"description": "when it was started, RFC 3339",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"process",
|
||||
"kind"
|
||||
]
|
||||
},
|
||||
"ProcessBuilds": {
|
||||
"type": "object",
|
||||
"description": "what process-builds answers",
|
||||
"properties": {
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node"
|
||||
},
|
||||
"processes": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/ProcessBuild"
|
||||
},
|
||||
"description": "every process the node-engine started, by module"
|
||||
},
|
||||
"error": {
|
||||
"type": "string",
|
||||
"description": "why they could not be read"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"node",
|
||||
"processes"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+1564
-7
File diff suppressed because it is too large
Load Diff
+159
-2
@@ -176,7 +176,79 @@
|
||||
}
|
||||
}
|
||||
],
|
||||
"description": "The merge check's tries: start one, read one, end one. The checker's own events stay under its own subjects (ADR 0620 §2).",
|
||||
"description": "The merge check's tries: start one, read one, end one. The seat says each check's end as checked and what the checker owes the forge as owed; the checker's other events stay under its own subjects (ADR 0620 \u00a72).",
|
||||
"family": {
|
||||
"name": "mesh-delivery-checker.events",
|
||||
"max-age-days": 7
|
||||
},
|
||||
"events": [
|
||||
{
|
||||
"name": "checked",
|
||||
"body": {
|
||||
"type": "object",
|
||||
"description": "a candidate checked: its entries judged at the group's heads (design 47 *What each step says*)",
|
||||
"properties": {
|
||||
"group": {
|
||||
"type": "string",
|
||||
"description": "the group, its branch"
|
||||
},
|
||||
"heads": {
|
||||
"type": "string",
|
||||
"description": "the heads checked, 12 hex digits, as the candidate's revisions are keyed"
|
||||
},
|
||||
"source": {
|
||||
"type": "integer",
|
||||
"description": "the source revision the heads are merged onto"
|
||||
},
|
||||
"catalog": {
|
||||
"type": "integer",
|
||||
"description": "the candidate's catalog graph revision judged, by its number on the seat mesh-catalog"
|
||||
},
|
||||
"verdict": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"pass",
|
||||
"fail",
|
||||
"could not run"
|
||||
],
|
||||
"description": "pass, fail, or could not run when a part the check needs did not answer"
|
||||
},
|
||||
"words": {
|
||||
"type": "string",
|
||||
"description": "what failed first, or the part not heard"
|
||||
},
|
||||
"entries": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/defs/CheckedEntry"
|
||||
},
|
||||
"description": "the entries checked"
|
||||
},
|
||||
"at": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"group",
|
||||
"heads",
|
||||
"verdict"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "owed",
|
||||
"subject": "owed.<repository>.<number>",
|
||||
"body": {
|
||||
"$ref": "#/defs/Owed"
|
||||
},
|
||||
"keep": {
|
||||
"max-age-days": 7,
|
||||
"max-mib": 64
|
||||
}
|
||||
}
|
||||
],
|
||||
"holder-events": [
|
||||
{
|
||||
"name": "verdict",
|
||||
@@ -746,5 +818,90 @@
|
||||
"description": "the previews of a head merged onto a trunk",
|
||||
"history": 5
|
||||
}
|
||||
]
|
||||
],
|
||||
"defs": {
|
||||
"Owed": {
|
||||
"type": "object",
|
||||
"description": "the status the checker owes the forge for a head, said under its id and safe to repeat (a status replaces what stands); the forge bridge performs it through the seat git's verb status (design 47 *What the gate owes the forge*)",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "the act's id, the same each time it is said again"
|
||||
},
|
||||
"act": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"status"
|
||||
],
|
||||
"description": "the act: always status"
|
||||
},
|
||||
"repository": {
|
||||
"type": "string",
|
||||
"description": "the repository, <owner>/<name>",
|
||||
"minLength": 1
|
||||
},
|
||||
"number": {
|
||||
"type": "integer",
|
||||
"description": "the pull request's number"
|
||||
},
|
||||
"head": {
|
||||
"type": "string",
|
||||
"description": "the pull request's head the status is on",
|
||||
"pattern": "^[0-9a-f]{40}$"
|
||||
},
|
||||
"context": {
|
||||
"type": "string",
|
||||
"description": "its context, mesh/check"
|
||||
},
|
||||
"state": {
|
||||
"type": "string",
|
||||
"description": "pending, success, failure or error"
|
||||
},
|
||||
"description": {
|
||||
"type": "string",
|
||||
"description": "what it says"
|
||||
},
|
||||
"target": {
|
||||
"type": "string",
|
||||
"description": "the page it links to"
|
||||
},
|
||||
"said": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "when the checker first said it"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"act",
|
||||
"repository",
|
||||
"number",
|
||||
"head",
|
||||
"context",
|
||||
"state"
|
||||
]
|
||||
},
|
||||
"CheckedEntry": {
|
||||
"type": "object",
|
||||
"description": "one entry of the candidate checked: a module at its fingerprint",
|
||||
"properties": {
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the module"
|
||||
},
|
||||
"fp": {
|
||||
"type": "string",
|
||||
"description": "the entry's fingerprint"
|
||||
},
|
||||
"node": {
|
||||
"type": "string",
|
||||
"description": "the node it was composed for, when the check composed it on one"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"module",
|
||||
"fp"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user