Why it matters
Docker/Kubernetes HEALTHCHECK or probes should hit a cheap /healthz — not a full dependency round-trip that flaps under load.
Practical steps
- Split liveness (/healthz) from readiness (/readyz checks deps).
- Keep liveness trivial so orchestrators do not kill busy bots.
- Use readiness to drain before deploy.
- Log probe failures with reason codes.
- Align probe timing with graceful shutdown grace period.
Watch out for
- Liveness that queries Postgres and Discord every 5s.
- No SIGTERM handler while probes expect instant death.