From be3152e184182b3e743ba5119217149fee908bd2 Mon Sep 17 00:00:00 2001 From: Joseph Doherty Date: Fri, 31 Jul 2026 12:00:17 -0400 Subject: [PATCH] =?UTF-8?q?docs(raw):=20record=20that=20a=20raw=20rename?= =?UTF-8?q?=20rebinds=20live=20=E2=80=94=20#489=20closed=20as=20fixed-by-#?= =?UTF-8?q?516?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Re-ran #489's own repro recipe on docker-dev. It does not reproduce: renaming pymodbus/plc/HR200X -> HR200Z and deploying (no node restart, container at 0 restarts) yields the new raw NodeId serving live ~1 Hz data, the old NodeId gone with BadNodeIdUnknown, and the UNS projection still Good. The mechanism is NOT the ApplyDelta/ReinitializeAsync chain the issue's 2026-07-26 code-trace predicted. The node log shows a stop-and-respawn: DriverHost: stopped driver child MAIN-modbus DriverHost: spawned Modbus driver MAIN-modbus (stub=False) DriverInstance MAIN-modbus: subscribed to 2 refs (poll-sub-1) #516 moved a DriverConfig change out of toDelta and into toStop+toSpawn so the factory is the single parse authority. A rename changes the merged DriverConfig, so the child is rebuilt against the new RawPaths and re-subscribes on the same deploy. #489 was fixed as a side effect and needs no code change. Also gated the sibling case the issue did not cover: renaming the *device* (the middle RawPath segment, plc -> plcz) rebinds identically. Records the operator-facing fact in docs/Raw.md, including the flip side #516 accepts — a rename reconnects the driver, briefly dropping every tag on it. Claude-Session: https://claude.ai/code/session_015p7wGqy3YpZNCpDzTpGMKo --- docs/Raw.md | 7 +++++++ docs/plans/2026-07-16-v3-batch4-PR.md | 7 ++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/docs/Raw.md b/docs/Raw.md index 69c8a6dc..03f7836b 100644 --- a/docs/Raw.md +++ b/docs/Raw.md @@ -32,6 +32,13 @@ points at it — the error names the referencing equipment). Renames return non- **warnings**: renaming a node changes the RawPath of every historized / UNS-referenced tag beneath it (its historian tagname / UNS projection path moves). +**A rename rebinds live data on the deploy — no node restart is needed** (Gitea #489, live-gated +2026-07-31 for both a tag rename and a device rename). The mechanism is #516's respawn: a rename +changes the merged `DriverConfig`, and `DriverSpawnPlan.Compute` stops and respawns the driver child +on any `DriverConfig` change, so the driver rebuilds against the new RawPaths and re-subscribes. +⚠️ The flip side is that **a rename reconnects the driver** — briefly dropping every tag on it, not +just the renamed one. That is the accepted cost #516 documents; it is not specific to renames. + ## Endpoint → DeviceConfig (the channel/device split) v3 moves the **connection endpoint** off the driver and onto the **Device** (`DeviceConfig`), diff --git a/docs/plans/2026-07-16-v3-batch4-PR.md b/docs/plans/2026-07-16-v3-batch4-PR.md index 3b6d305f..86f4db84 100644 --- a/docs/plans/2026-07-16-v3-batch4-PR.md +++ b/docs/plans/2026-07-16-v3-batch4-PR.md @@ -81,6 +81,11 @@ dedup/02-S13 semantics intact; M1/M2/LOW-3 closed. renamed tag live (3610→3611 Good); the **absolute** RawPath script literal (`Cval`) now fails **Bad 0x80000000**. (Caveat: a raw-tag rename needs a node recreate/restart to hot-rebind the renamed tag's live driver value — the pre-existing deploy-THEN-recreate pattern for structural edits.) + > **Superseded 2026-07-31 — the caveat above no longer holds.** #516 turned a `DriverConfig` change into a + > stop-and-respawn of the driver child (`DriverSpawnPlan.Compute`), and a rename changes the merged + > `DriverConfig`, so the child is rebuilt against the new RawPaths and re-subscribes on the same deploy. + > Re-gated live on docker-dev: renaming a tag *and* renaming a device each rebound to live ~1 Hz data with + > the node at `0 restarts`. Issue #489 closed as fixed-by-#516. 7. **Redundancy** — ServiceLevel split **central-1 = 250 / central-2 = 240** (both Good) — the Primary/Secondary differentiation is intact with the second namespace present; single-emit-per-condition is unit-covered (the alarm-emit gate is Primary-only). @@ -113,7 +118,7 @@ dual-namespace + event-delivery), Runtime 377 (+ VT reassert regression), AdminU historian issue). Proposed shape: a host-driven, node-only `AlarmStateUpdate` re-assert in `OnAlarmsLoaded` (same safe post-materialise ordering as the VT fix), reusing `_engine.GetState(alarmId)` + `LoadedAlarmIds`, **never touching the `alerts` topic**. -- Raw-tag rename hot-rebind of the renamed tag's live value without a recreate (today: deploy-THEN-recreate). Filed as issue #489. +- ~~Raw-tag rename hot-rebind of the renamed tag's live value without a recreate (today: deploy-THEN-recreate). Filed as issue #489.~~ **CLOSED 2026-07-31** — fixed as a side effect of #516's config-change respawn; live-re-gated, no code change needed. - Absolute-path Monaco completion → RawPath (from Batch 3; the `{{equip}}/` completion works). Filed as issue #490. - Cross-repo (post-merge): ScadaBridge Data-Connection-Layer NodeId/namespace cutover (raw `s=` / UNS `s=///`, retired `EquipmentNodeIds`) — tracked in the