Add diagnostics for Alert Dismissal#721
Merged
erikdarlingdata merged 11 commits intoerikdarlingdata:devfrom Mar 27, 2026
Merged
Add diagnostics for Alert Dismissal#721erikdarlingdata merged 11 commits intoerikdarlingdata:devfrom
erikdarlingdata merged 11 commits intoerikdarlingdata:devfrom
Conversation
- Parse detail_text to extract Database, Query Text, and Wait Type when using 'Mute This Alert' from alert history (both editions) - Add PopulateFromDetailText() to AlertMuteContext for structured field extraction from the label: value format - Add 'Default expiration for new mute rules' dropdown to Settings in both editions (1 hour, 24 hours, 7 days, Never; default 24h) - MuteRuleDialog now selects the configured default expiration instead of always defaulting to 'Never' - Persist setting as mute_rule_default_expiration in settings.json (Lite) and preferences.json (Dashboard) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The XML doc claimed Job Name extraction but the parser did not implement it. Add the missing branch in both Dashboard and Lite editions so the behavior matches the documentation. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Collapse newlines in Truncate/TruncateText so detail_text fields stay single-line in the label: value format - Handle multi-line query values in PopulateFromDetailText by accumulating continuation lines until the next indented field - Recognize variant query labels (Blocked Query, Blocking Query, Victim SQL) in addition to Query Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Explain that the field is a case-insensitive substring match and suggest entering a distinctive fragment like a table or procedure name. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Feature/alert muting part 2
…ingdata#718) Both editions gain a 'Log alert dismiss and mute actions' checkbox in Settings under Alert Muting. When enabled (the default), dismiss and mute operations write Info/Warn entries to the log file with row counts and diagnostic context. This helps troubleshoot issue erikdarlingdata#718 where dismiss stops working after many alerts accumulate. Lite: guards AppLogger calls behind App.LogAlertDismissals, persisted to settings.json as log_alert_dismissals. Dashboard: guards Logger calls behind UserPreferences.LogAlertDismissals, persisted to preferences.json via standard serialization. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Open
erikdarlingdata
approved these changes
Mar 27, 2026
Owner
erikdarlingdata
left a comment
There was a problem hiding this comment.
Clean, well-scoped diagnostic PR. The changes look good:
DismissAlertsAsyncreturningintis a nice improvement — callers can now detect partial updates and warn about parquet-archived rows.AND dismissed = FALSEin the WHERE clause is a good defensive addition.- Logging is properly gated behind
LogAlertDismissalsso there's no overhead when disabled.
Minor note: AlertsHistoryTab.xaml.cs line 75 adds an AppLogger.Debug call that isn't gated behind LogAlertDismissals (all the other new logging is). Debug level so likely fine, but inconsistent with the pattern.
Heads up — merge conflict incoming: PR #724 (per-server collector schedules) just merged into dev and changed the SettingsWindow.xaml.cs constructor signature and structure. This PR's patches to that file will conflict. The .xaml change (checkbox in the Notifications section) should be fine, but the .xaml.cs will need a rebase against current dev. Happy to help resolve if needed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Per the question #718 , this branch adds user-configurable diagnostic logging for Alert Dismissal and Muting, to help investigate why dismissal is not working under certain conditions.
Which component(s) does this affect?
How was this tested?
Tested Lite and Dashboard against SQL Server 2019 on-premises.
From Lite:
From Dashboard:
Checklist
dotnet build -c Debug)