https://github.com/arakelian/retry
A Java library to allow for the creation of configurable retrying strategies for an arbitrary function call, such as something that communicates with a remote service.
https://github.com/arakelian/retry
java java-11 retry retry-library retry-strategies retryer
Last synced: about 2 months ago
JSON representation
A Java library to allow for the creation of configurable retrying strategies for an arbitrary function call, such as something that communicates with a remote service.
- Host: GitHub
- URL: https://github.com/arakelian/retry
- Owner: arakelian
- License: apache-2.0
- Created: 2019-04-06T18:16:40.000Z (about 6 years ago)
- Default Branch: main
- Last Pushed: 2023-04-24T04:03:08.000Z (about 2 years ago)
- Last Synced: 2024-10-29T18:11:14.802Z (6 months ago)
- Topics: java, java-11, retry, retry-library, retry-strategies, retryer
- Language: Java
- Homepage:
- Size: 750 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: HISTORY.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# Retry
[](https://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22com.arakelian%22%20AND%20a%3A%22retry%22)
[](https://github.com/arakelian/retry/actions/workflows/ci.yml)The retry module provides a general purpose method for retrying arbitrary Java code with specific stop, retry,
and exception handling capabilities that are enhanced by Guava's predicate matching.This is a fork of the [guava-retrying](https://github.com/rholder/guava-retrying) library by Ryan Holder (rholder),
which is itself a fork of the [RetryerBuilder](http://code.google.com/p/guava-libraries/issues/detail?id=490) by
Jean-Baptiste Nizet (JB). The retry project added a Gradle build for pushing it up to Maven Central, and
exponential and Fibonacci backoff [WaitStrategies](http://rholder.github.io/guava-retrying/javadoc/2.0.0/com/github/rholder/retry/WaitStrategies.html)
that might be useful for situations where more well-behaved service polling is preferred.## Reasons for Fork
* Add Java 11 support
* Use java.util.Predicate and java.util.Function instead of Guava equivalents
* Make compatible with latest versions of Guava
* Fix all errorprone warnings in original source code## Requirements
* Versions < 6.0.0 require Java 8+
* Version 6+ require Java 11+## Installation
The library is available on [Maven Central](https://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22com.arakelian%22%20AND%20a%3A%22retry%22).
### Maven
Add the following to your `pom.xml`:
```xml
central
Central Repository
http://repo.maven.apache.org/maven2
true
...
com.arakelian
retry
6.0.1
test```
### Gradle
Add the following to your `build.gradle`:
```groovy
repositories {
mavenCentral()
}dependencies {
testCompile 'com.arakelian:retry:6.0.1'
}
```## Licence
Apache Version 2.0
## Documentation
Javadoc can be found [here](http://rholder.github.io/guava-retrying/javadoc/2.0.0).## License
The retry module is released under version 2.0 of the [Apache License](http://www.apache.org/licenses/LICENSE-2.0).## Contributors
* Jean-Baptiste Nizet (JB)
* Jason Dunkelberger (dirkraft)
* Diwaker Gupta (diwakergupta)
* Jochen Schalanda (joschi)
* Shajahan Palayil (shasts)
* Olivier Grégoire (fror)
* Andrei Savu (andreisavu)
* (tchdp)
* (squalloser)
* Yaroslav Matveychuk (yaroslavm)
* Stephan Schroevers (Stephan202)
* Chad (voiceinsideyou)
* Kevin Conaway (kevinconaway)
* Alberto Scotto (alb-i986)
* Ryan Holder(rholder)