From 29162d170c22826623a79c57f99385e250530b9d Mon Sep 17 00:00:00 2001 From: jochen Date: Sun, 22 Nov 2026 01:46:25 +0100 Subject: [PATCH] B5 (H-A-435 second addendum): the builder's process health stays kind unit, builder_health a tool beside it MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit A tool-only health is refused by the validator (ADR 0227 rule 8, ADR 0240 rule 2), as the runner's manifest has it: the unit check stays, the tool reads the consumers beside it. Builds: design 47 H2 §794; H-A-435 second addendum --- modules/mesh-delivery-builder/manifest_test.go | 7 ++++--- modules/mesh-delivery-builder/module.json | 3 +-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/modules/mesh-delivery-builder/manifest_test.go b/modules/mesh-delivery-builder/manifest_test.go index 33b9a37e0..73018a52a 100644 --- a/modules/mesh-delivery-builder/manifest_test.go +++ b/modules/mesh-delivery-builder/manifest_test.go @@ -244,9 +244,10 @@ func TestManifestProcess(t *testing.T) { // 1607/AC1 if p["artifact"] != "program" || !reflect.DeepEqual(p["run"], []any{"./mesh-delivery-builder"}) { t.Errorf("process = %v", p) } - // Design 47 H2 §794, H-A-435: the health asks builder_health, which names a consumer behind by five minutes. - if h, _ := p["health"].(map[string]any); h["kind"] != "tool" || h["tool"] != "builder_health" { - t.Errorf("health = %v, want the tool builder_health", p["health"]) + // Design 47 H2 §794, H-A-435 (second addendum): the process's health stays kind unit, builder_health a tool beside it (a + // tool-only health is refused, ADR 0227 rule 8, ADR 0240 rule 2). + if h, _ := p["health"].(map[string]any); h["kind"] != "unit" || len(h) != 1 { + t.Errorf("health = %v, want kind unit alone", p["health"]) } env, _ := p["env"].(map[string]any) if len(env) != 8 || env["MESH_BUILDER_REVISION_WAIT_FILE"] != "${dir:state}/revision-wait-minutes" || env["MESH_BUILDER_PACKAGE_WAIT_FILE"] != "${dir:state}/package-wait-minutes" || env["MESH_BUILDER_PUBLISH_TRIES_FILE"] != "${dir:state}/publish-tries" || env["MESH_BROKER_FILE"] != "${dir:state}/broker" || env["MESH_BUILDER_TOOLCHAIN_WAIT_FILE"] != "${dir:state}/toolchain-wait-minutes" { diff --git a/modules/mesh-delivery-builder/module.json b/modules/mesh-delivery-builder/module.json index 5ed620a68..e5e072fb8 100644 --- a/modules/mesh-delivery-builder/module.json +++ b/modules/mesh-delivery-builder/module.json @@ -346,8 +346,7 @@ }, "user": "mesh-delivery-builder", "health": { - "kind": "tool", - "tool": "builder_health" + "kind": "unit" } } ],