public abstract class ExecutionEvent extends Object
Modifier and Type | Method and Description |
---|---|
int |
getAttemptCount()
Gets the number of execution attempts so far, including attempts that are blocked before being executed, such as
when a
CircuitBreaker is open. |
Duration |
getElapsedAttemptTime()
Returns the elapsed time since the last execution attempt began.
|
Duration |
getElapsedTime()
Returns the elapsed time since initial execution began.
|
int |
getExecutionCount()
Gets the number of completed executions so far.
|
Optional<Instant> |
getStartTime()
Returns the time that the initial execution started, else
Optional.empty() if an execution has not started yet. |
boolean |
isFirstAttempt()
|
boolean |
isRetry()
|
public Duration getElapsedTime()
public int getAttemptCount()
CircuitBreaker
is open. Will return 0
when the first
attempt is in progress or has yet to begin.public int getExecutionCount()
CircuitBreaker
is open, are not counted. Will return 0
when the first
attempt is in progress or has yet to begin.public Optional<Instant> getStartTime()
Optional.empty()
if an execution has not started yet.public Duration getElapsedAttemptTime()
public boolean isFirstAttempt()
public boolean isRetry()
Copyright © 2022. All rights reserved.