A Rust utility library for fault tolerance, including retry strategies, backoff mechanisms, failure handling and much more.
π Loved the work? Subscribe to my YouTube channel or consider giving this repository a β to show your support!
Feature Overview
Synchronous Features
- β Retry β Stable
- β Retry with Backoff β Stable
- β Retry with Custom Conditions β Stable
- β Retry with Backoff & Custom Conditions β Stable
- π οΈ Retry with fallback - Planned
Asynchronous Features
- β Retry β Stable
- β Retry with Backoff β Stable
- β Retry with Custom Conditions β Stable
- β Retry with Backoff & Custom Conditions β Stable
- π οΈ Circuit Breaker β Planned
- π οΈ Retry with fallback - Planned
General
- β Logging
- π οΈ More Examples β Planned
π¦ How to Use resilient-rs
Hereβs a quick example of how to use the resilient-rs crate in your Rust project.
1οΈβ£ Add resilient-rs to Your Cargo.toml
Add the following line to your Cargo.toml file:
[]
= "0.4.0" # Replace with the latest version
OR
Synchronous
use Duration;
use RetryConfig;
use retry;
Asynchronous
use Duration;
use Client;
use retry;
use RetryConfig;
async
async
π Contributing Guidelines
We welcome your contributions! Here's how to get started:
π Issues & π Features
- Find an issue or planned feature you'd like to work on.
- Comment on the issue (or create one for planned features) and tag me (
@semicolon-10) for assignment.
π‘ Tip: Ensure it's not already assigned! - Once assigned, start working. π
π§ Submitting Work
- π΄ Fork the repo and create a new branch.
- π οΈ Make changes and test thoroughly.
- β Ensure git actions pass before tagging me for review.
- π€ Submit a PR with a clear description and link the issue.
π€ Code of Conduct
- Be respectful and collaborative. π€
- Follow coding standards and guidelines. β