From 72e1676d6179087fd9b549ee61d21ad8dbe2645e Mon Sep 17 00:00:00 2001 From: jochen Date: Thu, 5 Nov 2026 16:08:35 +0100 Subject: [PATCH] =?UTF-8?q?Assigner:=20the=20module=20graph=20is=20served?= =?UTF-8?q?=20from=20the=20node-engine's=20haves,=20the=20adapter=20and=20?= =?UTF-8?q?the=20last=20go/delivery=20import=20are=20gone=20(ADR=200634=20?= =?UTF-8?q?=C2=A75;=20issue=201966)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Claude-Session: https://claude.ai/code/session_01NcbgfFSnn24M3GcqttoU7i --- .../cmd/mesh-delivery-assigner/verbs.go | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/modules/mesh-delivery-assigner/cmd/mesh-delivery-assigner/verbs.go b/modules/mesh-delivery-assigner/cmd/mesh-delivery-assigner/verbs.go index 3951f82e..c3607709 100644 --- a/modules/mesh-delivery-assigner/cmd/mesh-delivery-assigner/verbs.go +++ b/modules/mesh-delivery-assigner/cmd/mesh-delivery-assigner/verbs.go @@ -3,13 +3,11 @@ package main import ( "context" "git.novox.be/novox/mesh-contracts/go/clients/nodeengineclient" - "git.novox.be/novox/mesh-contracts/go/seats/nodeengine" "git.novox.be/novox/mesh-delivery/modules/mesh-delivery-builder/builds" "mesh-delivery-assigner/internal/buckets" "slices" "git.novox.be/novox/mesh-sdk/go/catalogue" - "git.novox.be/novox/mesh-sdk/go/delivery" "git.novox.be/novox/mesh-delivery/sdk/graph" @@ -66,7 +64,7 @@ func (p *passer) served(ctx context.Context, get getter, g graph.Graph, n assign if len(g) == 0 { return nil } - served, unread := graph.Served(graphHaves(n.Haves), func(module, fp string) ([]string, bool) { return p.servesOf(ctx, get, module, fp) }, + served, unread := graph.Served(n.Haves, func(module, fp string) ([]string, bool) { return p.servesOf(ctx, get, module, fp) }, func(module string) []string { return g[module].Serves }) if len(unread) > 0 { p.logf("the manifest of the running build of %v cannot be read, so what the module graph says they serve is counted as served", unread) @@ -130,16 +128,3 @@ func (p *passer) manifestOf(ctx context.Context, get getter, module, fp string) } return got.manifest, true } - -// graphHaves is the haves as the module graph's Served reads them, which keeps the earlier have form for what it reads: the -// build, the phase and the health of each module on each node. -func graphHaves(haves map[string]map[string]nodeengine.HaveByNodeModuleValue) map[string]map[string]delivery.Have { - out := map[string]map[string]delivery.Have{} - for node, modules := range haves { - out[node] = map[string]delivery.Have{} - for module, h := range modules { - out[node][module] = delivery.Have{FP: h.Fp, Build: h.Build, Phase: delivery.Phase(h.Phase), Health: delivery.Health(h.Health)} - } - } - return out -}