Package io.micronaut.retry.event
Class RetryEvent
- java.lang.Object
-
- java.util.EventObject
-
- io.micronaut.context.event.ApplicationEvent
-
- io.micronaut.retry.event.RetryEvent
-
- All Implemented Interfaces:
java.io.Serializable
public class RetryEvent extends io.micronaut.context.event.ApplicationEventAn event triggered on each retry.- Since:
- 1.0
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description RetryEvent(io.micronaut.aop.MethodInvocationContext<?,?> source, RetryState retryState, java.lang.Throwable throwable)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RetryStategetRetryState()io.micronaut.aop.MethodInvocationContext<?,?>getSource()java.lang.ThrowablegetThrowable()
-
-
-
Constructor Detail
-
RetryEvent
public RetryEvent(io.micronaut.aop.MethodInvocationContext<?,?> source, RetryState retryState, java.lang.Throwable throwable)- Parameters:
source- The source method invocation context for intercepting method callretryState- To encapsulate current state intoRetryablethrowable- The error
-
-
Method Detail
-
getRetryState
public RetryState getRetryState()
- Returns:
- The retry context
-
getThrowable
public java.lang.Throwable getThrowable()
- Returns:
- The exception that caused the retry
-
getSource
public io.micronaut.aop.MethodInvocationContext<?,?> getSource()
- Overrides:
getSourcein classjava.util.EventObject
-
-