A lightweight, zero-dependency Java library for implementing fault tolerance and resilience patterns.
Failsafe is a lightweight, zero-dependency library for handling failures in Java applications. It provides resilience patterns like retry, circuit breaker, rate limiting, timeout, bulkhead, and fallback to help developers build robust systems that can gracefully handle intermittent faults and failures.
Java developers building distributed systems, microservices, or any application that needs to handle failures and improve reliability.
Developers choose Failsafe for its concise API, flexibility in composing resilience policies, and zero-dependency design, making it easy to integrate into existing Java projects without adding bloat.
Fault tolerance and resilience patterns for the JVM
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Failsafe has no external dependencies, making it easy to add to any Java project without risking version conflicts or bloating the classpath.
The library offers a simple API for wrapping code with resilience policies, allowing developers to quickly implement retry logic or circuit breakers with minimal boilerplate.
Policies like Retry, CircuitBreaker, and Timeout can be seamlessly combined, enabling tailored resilience strategies for complex distributed systems.
With its minimal footprint, Failsafe is efficient and suitable for high-performance environments like microservices, where resource usage is critical.
While modules exist for OkHttp and Retrofit, Failsafe lacks the extensive ecosystem of integrations found in libraries like Resilience4j, requiring custom code for other frameworks.
The library does not provide metrics or monitoring tools out of the box, so developers must implement their own solutions to track the health and performance of resilience policies.
When composing multiple policies, the configuration can become intricate, and ensuring correct behavior under all failure scenarios requires thorough testing and expertise.