Understanding the Circuit Breaker
⚙️ Advanced
·
Updated 3 weeks ago
Understanding the Circuit Breaker
What Does It Do?
When a backend fails repeatedly, the circuit breaker blocks all requests temporarily and immediately returns 503 Service Unavailable. This prevents requests from hanging on a dead backend.
Prerequisite
Uptime Monitoring must be enabled — the circuit breaker uses the monitoring results.
State Machine
| Status | Behavior |
|---|---|
| Closed | Normal — all requests go to the backend |
| Open | Blocked — immediate 503, no backend contact |
| Half-Open | Test — one request is let through. Success → Closed, failure → Open |
Configuration
- Threshold: Consecutive failures before the breaker opens (default: 5)
- Timeout: Seconds until a retry is allowed (default: 30)
Manual Reset
In the route list: Click on the Circuit Breaker badge → "Reset".