public class RetryPolicy extends Object
| Constructor and Description |
|---|
RetryPolicy(int retryTimeOut,
int retryNumber,
int heartbeat) |
RetryPolicy(int retryTimeOut,
int retryNumber,
int heartbeat,
Class<? extends Exception> retryableException) |
RetryPolicy(int retryTimeOut,
int retryNumber,
int heartbeat,
List<Class<? extends Exception>> retryableExceptions)
Create policy using provided values.
|
| Modifier and Type | Method and Description |
|---|---|
List<Class<? extends Exception>> |
getExceptions() |
int |
getHeartbeat() |
int |
getRetryNumber() |
int |
getRetryTimeOut() |
TimeUnit |
getTimeUnit() |
boolean |
isHeartbeat() |
void |
setHeartbeat(boolean isHeartbeat) |
void |
setTimeUnit(TimeUnit timeUnit) |
public RetryPolicy(int retryTimeOut,
int retryNumber,
int heartbeat,
List<Class<? extends Exception>> retryableExceptions)
retryTimeOut - - Integer value which is used as timeout between operation retry
combined with TimeUnit which is set to milliseconds by default.retryNumber - - Integer value which defines number of retry attempts.heartbeat - - Integer value which defines heart beat.retryableExceptions - - List of retryable exceptions.public RetryPolicy(int retryTimeOut,
int retryNumber,
int heartbeat)
public int getRetryTimeOut()
public int getRetryNumber()
public int getHeartbeat()
public TimeUnit getTimeUnit()
public void setTimeUnit(TimeUnit timeUnit)
public boolean isHeartbeat()
public void setHeartbeat(boolean isHeartbeat)
Copyright © 2015. All Rights Reserved.