From 98dbf4893163e3c68a7f48f8ae0b0aaddb2cd9b7 Mon Sep 17 00:00:00 2001 From: Erik Darling <2136037+erikdarlingdata@users.noreply.github.com> Date: Thu, 19 Feb 2026 17:39:09 -0500 Subject: [PATCH] Fix NOC deadlock severity using extended events timestamp (#170) DeadlockSeverity was only checking the perfmon counter delta between poll cycles, so deadlocks that occurred before Dashboard startup or between the first two polls showed green. Now also checks LastDeadlockMinutesAgo from extended events: <=10 min = Critical, <=60 min = Warning. Added missing OnPropertyChanged notification so the severity dot updates when the timestamp arrives. Closes #170 Co-Authored-By: Claude Opus 4.6 --- Dashboard/Models/ServerHealthStatus.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Dashboard/Models/ServerHealthStatus.cs b/Dashboard/Models/ServerHealthStatus.cs index 4b4795c5..8094cd74 100644 --- a/Dashboard/Models/ServerHealthStatus.cs +++ b/Dashboard/Models/ServerHealthStatus.cs @@ -433,6 +433,8 @@ public HealthSeverity DeadlockSeverity get { if (DeadlocksSinceLastCheck > 0) return HealthSeverity.Critical; + if (_lastDeadlockMinutesAgo.HasValue && _lastDeadlockMinutesAgo.Value <= 10) return HealthSeverity.Critical; + if (_lastDeadlockMinutesAgo.HasValue && _lastDeadlockMinutesAgo.Value <= 60) return HealthSeverity.Warning; return HealthSeverity.Healthy; } } @@ -447,6 +449,7 @@ public int? LastDeadlockMinutesAgo _lastDeadlockMinutesAgo = value; OnPropertyChanged(); OnPropertyChanged(nameof(DeadlockDetailText)); + OnPropertyChanged(nameof(DeadlockSeverity)); } }