ENG-3, ENG-4: the node-engine keeps no seat table of its own (mesh-contracts' list through mesh-sdk), answers ${seat:...:reach} for both names of the store, and reads both reference forms in composition, image seat and bootstrap (ADR 0605 §9, design 26, issue 1966)

Claude-Session: https://claude.ai/code/session_01JG73KJNrH5EgFXMKKYSrig
This commit is contained in:
2026-11-04 12:11:34 +01:00
parent 18c1735f7c
commit 7f33c8b499
16 changed files with 102 additions and 1133 deletions
+14 -6
View File
@@ -41,7 +41,7 @@ func artifactsInto(resource map[string]any, module string, with mcat.Rendering)
module, resource["id"], written, mcat.ArtifactStoreProvision)
}
resource[key] = mcat.Routed(written, with.ArtifactStore)
imageSeatInto(resource, key, with)
imageSeatInto(resource, key, written, with)
continue
}
if with.ArtifactStore == "" {
@@ -60,7 +60,7 @@ func artifactsInto(resource map[string]any, module string, with mcat.Rendering)
}
if with.Built[repository] {
resource[key] = mcat.Routed(recorded, with.ArtifactStore)
imageSeatInto(resource, key, with)
imageSeatInto(resource, key, written, with)
}
}
return nil
@@ -74,10 +74,18 @@ const artifactSeat = "mesh-artifact-store"
// *distribution's first delivery*, issue 1966 ENG-10), so the node-engine finds by the declaration whom a failed pull waits
// on, never by a module's name. Neither is part of what a container is: a declaration composed again for a new holder
// replaces no container. Nothing is written where the holder is not on record, or for a resource that is no container.
func imageSeatInto(resource map[string]any, key string, with mcat.Rendering) {
if key != "image" || resource["type"] != "container" || with.SeatHolder[artifactSeat] == "" {
func imageSeatInto(resource map[string]any, key, written string, with mcat.Rendering) {
if key != "image" || resource["type"] != "container" {
return
}
resource["image-seat"] = artifactSeat
resource["image-holder"] = with.SeatHolder[artifactSeat]
// The seat a reference of the registry form names; the older forms came through the artifact store's.
seat := artifactSeat
if named, _, ok := mcat.InRegistrySeat(written); ok {
seat = named
}
if with.SeatHolder[seat] == "" {
return
}
resource["image-seat"] = seat
resource["image-holder"] = with.SeatHolder[seat]
}