DriverInstanceResilienceStatus: dead table — same defect as #521, keep or delete #524
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?
Found while resolving #521, and deliberately not folded into it — deleting a second table was beyond what that issue asked for.
What is true today
DriverInstanceResilienceStatushas no writer and no reader. The only reference in the whole repo is theDriverInstanceResilienceStatusesDbSet declaration inOtOpcUaConfigDbContext. Every deployment's copy of this table is empty.DriverHostStatus, which no longer exists — dropped in #521.MemoryTracking+MemoryRecycleas its data sources; both were deleted in #522.The doc-comment has been rewritten to state the truth. The entity itself is untouched.
Why it is dead for exactly the reason #521's table was
Per-cluster mesh Phase 4 gates
AddOtOpcUaConfigDbon theadminrole, so a driver-only node has no ConfigDb connection to write rows with. Any per-node runtime status table has the same problem.The live data already exists and does not go through SQL: resilience state reaches the AdminUI as
DriverResilienceStatusChangedover the Phase 5 gRPC telemetry stream into the in-memoryIDriverResilienceStatusStore— the same channel #521 adopted for per-host connectivity.The decision
(a) Delete it. Drop the entity, the DbSet, the model config, and the table (migration), mirroring #521's
DropDriverHostStatusTable. The telemetry channel already delivers this data; the table is a permanently-empty schema object whose doc-comment misled twice.(b) Keep it as a durable history sink. The one thing telemetry does not give you is history across a central restart — the in-memory store is last-value-only. If breaker-trip history is wanted, this table is a reasonable home, but it would need a central-side writer fed by the telemetry stream (not a driver-node writer, which Phase 4 rules out).
(a) is the straightforward read given nothing has needed it. Worth an explicit decision rather than inference, same as #521 and #522.
Resolved on master
ba85e871— option (a), delete.Everything this issue asserted held up on re-verification, and the deciding fact was that the live data was never actually missing:
IDriverResilienceStatusStoreis genuinely consumed —DriverStatusPanel.razorinjects it, fed by bothDriverResilienceStatusBridge(DPS) andTelemetryDialSupervisor(gRPC). So resilience counters already reach the AdminUI; the table contributed nothing but a permanently-empty schema object whose doc-comment misled twice.Dropped: the entity, the DbSet, the model config, and the table (migration
DropDriverInstanceResilienceStatusTable).Down()recreates it exactly, and the scaffolder's data-loss warning cannot bite on a table nothing ever inserted into.Also corrected en route:
DriverResilienceStatusTracker's doc-comment claimedCurrentInFlightfedDriverInstanceResilienceStatus.CurrentBulkheadDepth"until the full telemetry observer lands". The observer landed in Phase 5; the table never had a writer.SchemaComplianceTestscaught the drop as intended — that guard is live, not decorative (it failed when #521's table was removed from the DbContext without updating it).