From 1028193c8a30efea1ffc4c55608aec7cd48decb6 Mon Sep 17 00:00:00 2001 From: jochen Date: Wed, 30 Sep 2026 13:46:51 +0200 Subject: [PATCH] A delivered host knows it is the delivered one MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit novox/hq 04-ISSUES/163. The host asks after every apply whether a newer host is delivered than the one running, and asked with the link-time version stamp — which every delivered host carries as "development build", because the version comes from where the binary sits now (0142). So a delivered host never matched the newest delivered version, stood aside on every push for ever, and because standing aside cancels the report, the mesh never heard from it again. Measured on two machines: each push produced "host is delivered; standing aside" for the version already running, then "applied, and could not tell the mesh: reporting: context canceled". A machine restarting its host on every push and reporting nothing, reading as healthy. Asked with the running version now. Half of 0142 was applied to the report and the known-good record and not here; this is the other half. --- cmd/mesh-host/main.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/cmd/mesh-host/main.go b/cmd/mesh-host/main.go index c410072..89cd8f0 100644 --- a/cmd/mesh-host/main.go +++ b/cmd/mesh-host/main.go @@ -1054,7 +1054,12 @@ func runLink(ctx context.Context, opts options) error { // standing before this machine leaves the one it is on (novox/hq design 28, task 5.2). adoptDeliveredMembership(identity.Path(opts.state), &mine, say) - switch next, waiting, err := upgrade.Successor(upgrade.VersionsDir(""), version); { + // Asked with the version this host is RUNNING, read from where it sits — not the link-time + // stamp, which every delivered host carries as "development build". Asked with the stamp, + // a delivered host never matched the newest delivered version, so it stood aside on every + // push for ever, and standing aside cancels the report, so the mesh never heard from it + // again (novox/hq 04-ISSUES/163). + switch next, waiting, err := upgrade.Successor(upgrade.VersionsDir(""), runningVersion()); { case err != nil: // Said, not fatal. A host that cannot read the delivered versions is still running this // machine correctly; what it has lost is the ability to be replaced. -- 2.54.0