Circuit Breaker
The circuit breaker protects your API and Staffify from cascading failures. If your API has repeated issues, the circuit breaker temporarily stops sync attempts.
How It Works
- Each failed sync increments a failure counter
- After 5 consecutive failures, the circuit breaker trips
- Syncs are blocked for 30 minutes
- After cooldown, you can try syncing again
- Successful sync resets the failure counter
When Circuit Breaker Trips
You'll see a warning in the Data Source card:
Circuit breaker triggered after 5 failures. Syncs blocked until [time]. Click Reset to try again.
Resetting the Circuit Breaker
- 1. Fix the underlying issue (check API credentials, endpoint URL, etc.)
- 2. Click the Reset button on the warning
- 3. Test your connection to verify it works
- 4. Try syncing again
Common Causes
| Issue | Cause | Solution |
|---|---|---|
| 401 Unauthorized | Token expired or invalid | Refresh token or re-enter credentials |
| 404 Not Found | Endpoint URL changed | Update endpoint paths |
| 500 Server Error | PMS API is down | Wait and try later, contact PMS support |
| Timeout | API too slow or unreachable | Check network, increase timeout |