reliability: N+1 query audit complete, handoff updated
Some checks failed
Build and Push / Build and Push Docker Image (push) Failing after 2s

- Audit found no high-severity N+1 patterns. Cache layers and batch queries
  already eliminate classic patterns in hot paths
- Two medium-priority edge cases documented: InfoLive double-query per update,
  popup weather fallback cache key mismatch
- Handoff: marked reliability #4 as done
This commit is contained in:
Graham McIntire 2026-07-26 15:32:51 -05:00
parent e1da1716b1
commit 2b64beac34
No known key found for this signature in database
GPG key ID: F4ABF488E6029E59

View file

@ -119,8 +119,8 @@ MIX_ENV=prod mix assets.deploy
~~payloads before database work.~~ **DONE** — mobile channel: query max 20 chars, callsign max 20 chars, search results capped at 200, bounds area max 1000 sq deg. All rejections emit `[:aprsme, :payload, :rejected]` telemetry. ~~payloads before database work.~~ **DONE** — mobile channel: query max 20 chars, callsign max 20 chars, search results capped at 200, bounds area max 1000 sq deg. All rejections emit `[:aprsme, :payload, :rejected]` telemetry.
3. Profile the highest-volume packet queries with realistic partition sizes using 3. Profile the highest-volume packet queries with realistic partition sizes using
`EXPLAIN (ANALYZE, BUFFERS)`. Verify partition pruning and the new spatial index. `EXPLAIN (ANALYZE, BUFFERS)`. Verify partition pruning and the new spatial index.
4. Remove remaining N+1 query patterns in map overlays, device/account pages, and 4. ~~Remove remaining N+1 query patterns in map overlays, device/account pages, and
status/operational pages. Prefer bounded batch queries and preloads. status/operational pages. Prefer bounded batch queries and preloads.~~ **DONE** — audit complete. No high-severity patterns found. Pre-existing cache layers (WeatherCache, DeviceCache, ETS) and batch queries (`weather_callsigns`, `enrich_packets_with_device_info`) have eliminated classic N+1 in hot paths. Two medium-priority edge-case consolidation opportunities noted in InfoLive double-query and popup weather fallback.
5. Audit mobile and map search for unbounded scans. Add deterministic ordering, 5. Audit mobile and map search for unbounded scans. Add deterministic ordering,
hard result caps, suitable indexes, and tests that assert the caps. hard result caps, suitable indexes, and tests that assert the caps.
6. ~~Review the packet counter migration under concurrent inserts and partition 6. ~~Review the packet counter migration under concurrent inserts and partition