Why Retry Matters
Bindu includes a built-in Tenacity-based retry mechanism to handle transient failures across workers, storage, schedulers, and API calls.| Without retry | With Bindu retry |
|---|---|
| Temporary failures surface as immediate task failures | Transient failures can recover automatically |
| Recovering services get hit again at the same time | Exponential backoff with jitter spreads retry pressure out |
| Worker, storage, and scheduler failures each need custom handling | The same retry approach covers all critical operation types |
| Troubleshooting depends on guesswork | Retry attempts and outcomes are logged |
| Tuning behavior requires code changes | Environment variables and overrides make tuning easier |
How Bindu Retry Works
Retry logic is applied across four main operation types: worker, storage, scheduler, and API calls.The Lifecycle: Fail, Wait, Try Again
Configuration
Environment Variables
Defaults
| Operation Type | Max Attempts | Min Wait | Max Wait |
|---|---|---|---|
| Worker | 3 | 1.0s | 10.0s |
| Storage | 5 | 0.5s | 5.0s |
| Scheduler | 3 | 1.0s | 8.0s |
| API | 4 | 1.0s | 15.0s |
Retry Decorators
Ad-Hoc Retry
For one-off retry logic without decorators:Best Practices
Troubleshooting
Reducemax_attempts or max_wait, and fix the underlying cause:
Monitoring And Observability
Retry attempts are logged automatically:- Retry rate
- Retry success rate
- Average retry attempts
- Retry duration
- Failure types