Polite Retry is a retry library for TypeScript and JavaScript that treats retries as production traffic, not harmless background noise.
Many retry libraries focus on trying again quickly. That works for small failures, but in distributed systems it can make outages worse. When services are already stressed, repeated retries can amplify load and turn a partial failure into a cascading one.
Polite Retry provides a safer set of retry patterns for real systems.
What it does
- Adds retry helpers with exponential backoff and jitter.
- Includes circuit breaker support to stop retrying when a dependency is unhealthy.
- Supports adaptive retry budgeting so retry volume can shrink when failure rates rise.
- Exposes retry metrics to help understand amplification and failure behavior.
- Works in TypeScript and JavaScript projects.
Why it matters
The goal is not just to retry failed calls. The goal is to retry in a way that gives the downstream system room to recover. Polite Retry is built around that constraint, making it useful for APIs, background jobs, service calls, and SDKs that need a more thoughtful retry policy.
Current status
The package has documentation, examples, and an npm release. It is a focused open source utility with a clear reliability angle.