use of com.peterphi.std.guice.common.retry.retry.backoff.ExponentialBackoff in project stdlib by petergeneric.
the class RetryMethodInterceptor method buildRetryManager.
private RetryManager buildRetryManager(Retry options) {
final Timeout initial = new Timeout(options.backoffTime(), options.backoffUnit());
ExponentialBackoff backoff = new ExponentialBackoff(initial, options.backoffExponent());
return new RetryManager(backoff, options.maxAttempts(), attempts, attemptFailures);
}
Aggregations