Error Diagnostics // TraceLite Bench
Redis Broker OOM & Celery Ack-Late Retry Storms
When Celery workers lag behind ingestion or fail on malformed payloads, Redis buffers unacknowledged JSON tasks in RAM until Redis hits maxmemory or triggers OOM.
Measured GlitchTip & Sentry Telemetry
Redis stores every queued event task in memory. During a 10x spike where ingestion outpaces Celery workers, Redis grows by 150-500 MB per 100k queued events. Using volatile-lru on a Celery broker corrupts task state—use noeviction plus a bounded memory limit and worker scaling.
| Subsystem / Signal | Measured Footprint | Operational Impact |
|---|---|---|
| Normal Redis 7 RSS (steady state) | 45 - 110 MB | Low overhead for queues and cache |
| Queued 250k Burst Backlog | 380 - 720 MB | Requires 512 MB+ maxmemory on 8 GB VPS |
| Safe Eviction Policy | noeviction | Prevents silent broker metadata corruption |
Step-by-Step Triage & Compose Remediation
- Inspect Redis used_memory: Run redis-cli INFO memory to separate active queue keys from fragmentation.
- Set explicit --maxmemory: Pass --maxmemory 256mb on 2-4 GB nodes or 512mb on 8 GB nodes with --maxmemory-policy noeviction.
- Drain stuck dead-letter bursts: Apply per-project rate limits in GlitchTip UI before scaling Celery concurrency.
docker compose exec redis redis-cli INFO memory | grep used_memory_human # Compose command: command: ["redis-server", "--maxmemory", "512mb", "--maxmemory-policy", "noeviction"]
Diagnostic FAQ
Should I set allkeys-lru on GlitchTip Redis?
No. Because Redis acts as the Celery task broker, evicting arbitrary keys breaks in-flight event ingestion.
How do I stop Redis from growing unbounded?
Pair Redis maxmemory with GlitchTip project event rate caps and sufficient Celery concurrency.