Phase 5 telemetry: existing deployments must populate ClusterNode.GrpcPort (seed only backfills fresh installs) #493
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context
Per-cluster mesh Phase 5 (gRPC live-telemetry stream, merged
35552a96) added a nullableClusterNode.GrpcPortcolumn. Central'sTelemetryDialSupervisorreads it to discover each drivernode's telemetry endpoint (
http://{Host}:{GrpcPort}) whenTelemetryDial:Mode=Grpc.The gotcha (surfaced by the Phase 5 live gate)
On an existing deployment,
GrpcPortisNULLafter upgrade, so central finds no dial targetsand the gRPC telemetry stream never connects — even with the dark switch flipped to
Grpc. Freshinstalls are unaffected.
Root cause
The DB/rig seed is idempotent INSERT-if-not-exists, so it never backfills a new nullable column
onto pre-existing
ClusterNoderows. (AkkaPort, added in an earlier phase, was unaffected onlybecause its column carries a NOT NULL default of 4053;
GrpcPortis nullable with no default, sopre-existing rows keep
NULL.)Symptom / how to spot it
Central logs, once per node (throttled — the code degrades gracefully, and last-known DPS panels are
unaffected since the flip is per-node):
docker exec <node> cat /proc/net/tcp6shows a
LISTENbut noESTABLISHED./alertsand/script-logconnection pill does not turn "live" in Grpc mode.Fix / operator action
Populate
ClusterNode.GrpcPortfor every driver node before/while flipping toGrpc— via the AdminUInode edit (Phase 1 surfaced the field) or a data update:
Suggested improvements (pick one or more)
docker-dev/seed/seed-clusters.sql) UPSERT the transport port columns(
AkkaPort/GrpcPort) so a persisted volume backfills on re-run instead of only fresh volumes.GrpcPort(default, or derived from each node's ownCluster:PublicHostname/config) for existing deployments upgrading to Phase 5.docs/Telemetry.md/ release notes.References
35552a96(feat/mesh-phase5)docs/plans/2026-07-23-mesh-phase5-live-gate.mddocs/Telemetry.mdNote: the code behaved correctly throughout (graceful throttled skip); this is a rig/upgrade data gap,
not a Phase 5 code defect.
Fixed on
fix/issues-503-501-493-499-488, commit8b7ea321. Took suggestions 1 and 3; deliberately not 2.Seed backfill.
docker-dev/seed/seed-clusters.sqlnow backfillsGrpcPortwhere itIS NULL AND CreatedBy = 'docker-dev-seed'→ 4056. NULL only — it must not overwrite a port an operator set deliberately on a long-lived dev volume, and NULL is the unambiguous "this row predates the column" marker. NoAkkaPortequivalent: it isNOT NULLwith a default of 4053, so there is nothing to backfill and a no-op UPDATE would only mislead.Docs.
docs/Telemetry.mdgains an upgrade section before "Reconnect and reliability": the prerequisite, the symptoms (the throttled skip log,LISTENwith noESTABLISHED, the pill never going live), and theUPDATEto run before flipping any node toGrpc.No EF data migration, on purpose. The correct value is each node's own
Telemetry:GrpcListenPort— per-deployment configuration the database cannot derive. A migration could only invent a value, and a wrong dial target is worse than the NULL the dialer already skips explicitly and gracefully: it would connect to something unintended, or fail in a way that looks like a live-telemetry bug rather than a missing setting. The rig is different precisely because there the port is fixed bydocker-compose.ymland therefore actually knowable. That reasoning is recorded in the doc so it is not re-litigated.