Files
beacon-server/db/sqlc
MrAlders0n bc3a375816 perf(stats): bucket payload & observer matviews by hour for windowed queries
The payload-breakdown and top-observers matviews stored a single 7-day
total per group, so the 24h/7d/30d selector did nothing: payload ignored
the window entirely (the store discarded `since`) and top-observers only
varied which rows cleared the last_heard cutoff, never the counts.

Bucket both views by hour over a 30-day horizon and sum the buckets in
range, mirroring mv_hourly_iata_stats. The stats endpoints now honour the
requested window while still reading a small precomputed table.
2026-07-24 12:07:05 -07:00
..
2026-05-22 11:43:27 -07:00