You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(dashboard): window the slop/duplicate trend read by time, not a 2-per-week row cap (#9803)
`SLOP_DUPLICATE_TREND_SNAPSHOT_LIMIT` was `WEEKS * 2 = 16` on the false premise
that queue-health snapshots are written twice a week. They are written up to once
per repo per generate-signal-snapshots run (several per day), so the row cap kept
only the most recent ~4 days and the 8-week trend card was almost entirely empty.
Add an optional `sinceIso` to `listRecentSignalSnapshotsForTargets`, applied as
`AND generated_at >= ?` INSIDE the windowed subquery so row_number() ranks over
the time-bounded set (not the whole table); the route passes an 8-week bound
derived from the request's generatedAt. `maxPerTarget` stays a hard backstop,
re-budgeted to WEEKS * 28 (clamped to the query's 100 ceiling). Omitting sinceIso
is byte-identical to today.
Closes#9699
0 commit comments