public class Invocation extends RetryStats
| Modifier and Type | Method and Description |
|---|---|
void |
complete()
Completes the associated
RecurrentFuture. |
boolean |
complete(Object result)
Completes the associated
RecurrentFuture with the result. |
boolean |
complete(Object result,
Throwable failure)
Completes the associated
RecurrentFuture with the result and failure. |
boolean |
completeExceptionally(Throwable failure)
Completes the associated
RecurrentFuture with the failure. |
boolean |
retry()
Retries a failed invocation.
|
boolean |
retryOn(Throwable failure)
Retries a failed invocation.
|
boolean |
retryWhen(Object result)
Retries a failed invocation.
|
boolean |
retryWhen(Object result,
Throwable failure)
Retries a failed invocation.
|
canRetryOn, canRetryWhen, canRetryWhen, getRetryCount, getWaitTimepublic void complete()
RecurrentFuture.IllegalStateException - if a complete method has already been calledpublic boolean complete(Object result)
RecurrentFuture with the result. Returns true on success, else false if
completion failed and should be retried via retryWhen(Object).IllegalStateException - if a complete method has already been calledpublic boolean completeExceptionally(Throwable failure)
RecurrentFuture with the failure. Returns true on success, else false if
completion failed and should be retried via RetryStats.canRetryOn(Throwable).IllegalStateException - if a complete method has already been calledpublic boolean complete(Object result, Throwable failure)
RecurrentFuture with the result and failure. Returns true on
success, else false if completion failed and should be retried via RetryStats.canRetryWhen(Object, Throwable).IllegalStateException - if a complete method has already been calledpublic boolean retry()
RecurrentFuture exceptionally if the retry policy has been exceeded.IllegalStateException - if a retry method has already been calledpublic boolean retryOn(Throwable failure)
failure, else returns false
and completes the associated RecurrentFuture exceptionally if the retry policy has been exceeded.NullPointerException - if failure is nullIllegalStateException - if a retry method has already been calledpublic boolean retryWhen(Object result)
result, else returns false
and completes the associated RecurrentFuture exceptionally if the retry policy has been exceeded.NullPointerException - if result is nullIllegalStateException - if a retry method has already been calledpublic boolean retryWhen(Object result, Throwable failure)
result and failure,
else returns false and completes the associated RecurrentFuture exceptionally if the retry policy has been
exceeded.IllegalArgumentException - if result and failure are both nullIllegalStateException - if a retry method has already been calledCopyright © 2015. All Rights Reserved.