Outbreak digest mode (batch notifications on high-activity days) #76
Labels
No labels
area:ai
area:ci-cd
area:notifications
area:observability
area:public-pages
backlog
bug
duplicate
enhancement
help wanted
invalid
question
type:decision
type:feature
type:infra
type:maintenance
type:security
v1.0.1
v1.1.0
v1.2.0
v1.3.0
v2.0.0
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
rbrooks/WeatherBot#76
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
On high-activity days the current design can send dozens of per-alert messages per channel; a per-subscription "digest above N alerts/hour" batching option. Real value, but interacts with F-11's delivery redesign — sequence after it. Effort M.
Filed from the 2026-07-17 codebase audit (
docs/.internal/report-2026-07-17.md), finding I-06.Done in #116 (merged). Per-subscription opt-in
digest_threshold(null = off, default): once a (channel, location) sub has sent that many alerts withinDIGEST_WINDOW_MINUTES(60), further advisory/watch alerts are batched and delivered as one periodic digest by aflush_alert_digestsjob everyDIGEST_FLUSH_MINUTES(30). The digest is a synthetic "Weather Alert Digest"NWSAlertdispatched through the existing per-notifier send path (no new per-notifier code), double-send-safe (pending flag cleared atomically with akind="digest"ledger row the outbox never re-drives), quiet-hours-aware, fail-soft per group.Safety decision: warning-class alerts are never batched — they always dispatch immediately (holding a life-safety warning up to the flush interval is unacceptable, and an operator taming advisory spam wouldn't expect it). Only advisories/watches digest. If you'd prefer everything batched during an outbreak instead, it's a one-line change. Migration 0028; 7 tests (incl.
test_warning_class_never_defers); bulk 746 passed.