Repository navigation
DESKTOP: the Blocking Trends and Blocking Stats charts say where their data starts (part of #4966) - #5030
Merged
Conversation
…re their data starts (part of #4966)
… Wait names the coverage alone; release at the join (#4966)
erikdarlingdata
marked this pull request as ready for review
October 3, 2026 19:49
erikdarlingdata
added a commit
that referenced
this pull request
Oct 4, 2026
…say where their data starts (part of #4966) (#5096) Lite's Blocking tab charts now show "Showing since <time>" when the chosen window starts before the store's data for that chart. Before, they drew zeros across the gap, as if nothing had happened. The five charts are the Lock Wait, Blocking and Deadlock trends on the Trends sub-tab, and the blocking and deadlock pairs on Blocking Stats. The wording and placement match the desktop viewer's #5030. Each note probes its own source: Lock Wait Trend probes the wait_stats collector (a new WaitStats window relation); the Blocking trend and the blocking pair probe the blocked process reports, which also count the DMV blocking snapshots; the Deadlock trend and the deadlock pair probe deadlocks. The notes run after the charts draw, over the same UTC window the reads took, through the shared banner step, so the 90-minute rule, the chart's time zone and the failed-probe rule match every other Lite note. The event charts name the earlier of the coverage start and the first event drawn (a zero bucket is not an event); the Lock Wait Trend, a rate series, names its coverage alone. Tests: 19 in BlockingChartsDataStartTests. Each chart has a notice test and a quiet-start test, and the zero-bucket and earliest-point helpers are covered. A pin checks that each note step calls its banner with its relation; it fails 5 of 5 with the notes turned off. Full Lite.Tests on Windows: 8,025 passed, 0 failed. Part of #4966
12 of 14 tasks
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.
Part of #4966.
Why
The Blocking > Trends and Blocking Stats charts draw zero baselines,
PadEndszero ends or a flat 0 when a read is empty, so a span before the data starts reads as "nothing happened".What changes
#22FFAA00, Auto row) per floor. Trends: one over each of the three charts. Stats: one over the blocking pair, one over the deadlock pair. The summary strip gets no separate note.GetBlockedProcessReportsDataStartAsync. Deadlock Trend and the Stats deadlock pair useGetDeadlocksDataStartAsync. Lock Wait Trend uses a newGetLockWaitTrendDataStartAsyncoverForCollectorTable("wait_stats")(the name resolves; the live test proves it).RenderLockWaitTrendChart), so it gets a note. Its points are rate buckets clamped to the window start, not events, so its note names the coverage start alone (UpdateTruncationBanneroverDataStartOrNullAsync, the Current Waits form).ShowEventDataStartAsyncnames the earlier of the coverage start and the first drawn point. Count charts use non-zero buckets only (BlockingTrendTimesDrawn).AwaitReadWatchingProbeAsync(nested: three probes on Trends, two on Stats), so a read that throws still watches its probes and a late probe failure is a warning, not an unobserved-exception error. A throwing probe costs only its note. Fan-out isOf(6)on Trends andOf(5)on Stats, released right after the watched join so the banner awaits are outside the scope.Limits
EventCount > 0(blocking) and every severity point (deadlock) as "drawn".wait_stats(what Lock Wait Trend draws from,v_wait_stats). Current Waits useswaiting_tasksbecause its charts read that table, so the two floors differ on purpose. Both go throughDataWindowFloor.GetForServerAsyncwithForCollectorTableandCurrentInteractiveReadSeconds.Test plan
ViewerBlockingChartsDataStart(internal static, no WPF).ViewerBlockingChartsDataStartTestsnow has 4 facts that need no STA thread (non-zero buckets only, earlier of coverage and first bucket, empty read, throwing probe viaViewerEventDataStart.Of(..., probeFailed: true)).ViewerBlockingChartsDataStartTests: Total 4, Failed 0.ViewerBlockingChartsDataStartPinTests: Total 3, Failed 0.ViewerBlockingChartsDataStartLiveTests(scratch store): Total 1, Failed 0.ViewerProbeWatchCensusTests; feeding Lock Wait from its drawn points fails the Trends pin;BlockingTrendTimesDrawnkeeping zero buckets fails the unit facts.ViewerEventDataStartTests.EveryTabRead_OfTheTwoGrids_HasItsProbeupdated to the new contract: 4 calls each toGetBlockedProcessReportsDataStartAsyncandGetDeadlocksDataStartAsync(two grid loads plus the Trends and Stats probes), still exact counts. It is a source-text fact. The class shows Total 29, Failed 12 locally, all 12 on the dev-local list (STA); the fact itself is not among them.ViewerProbeWatchCensusTests(3) andViewerCommandTimeoutTests(58) pass at the head.--no-incrementalbuild: 0 errors, 0 warnings.CHANGELOG
SECTION: Fixed
ENTRY: - The desktop viewer's Blocking Trends and Blocking Stats charts say where their data starts ([#5030]) - the Lock Wait, Blocking and Deadlock trend charts and the Blocking Stats charts now show "Showing since " when the range reaches before their data does, so an empty stretch no longer reads as no blocking. Each chart names its own source's start.
REF: [#5030]: #5030