Annotation Interface Retryable


AOP Advice that can be applied to any method.
Since:
1.0
Author:
graemerocher
  • Field Details

    • MAX_INTEGRAL_DIGITS

      static final int MAX_INTEGRAL_DIGITS
      The maximum integral digits for retry attempts validation.
      See Also:
  • Element Details

    • value

      @AliasFor(member="includes") Class<? extends Throwable>[] value
      Returns the exception types to include, which defaults to all.
      Returns:
      The exception types to include (defaults to all)
      Default:
      {}
    • includes

      Class<? extends Throwable>[] includes
      Returns the exception types to include, which defaults to all.
      Returns:
      The exception types to include (defaults to all)
      Default:
      {}
    • excludes

      Class<? extends Throwable>[] excludes
      Returns the exception types to exclude, which defaults to none.
      Returns:
      The exception types to exclude (defaults to none)
      Default:
      {}
    • attempts

      Returns the maximum number of retry attempts.
      Returns:
      The maximum number of retry attempts
      Default:
      "3"
    • delay

      String delay
      Returns the delay between retry attempts.
      Returns:
      The delay between retry attempts
      Default:
      "1s"
    • maxDelay

      String maxDelay
      Returns the maximum overall delay.
      Returns:
      The maximum overall delay
      Default:
      ""
    • multiplier

      Returns the multiplier to use to calculate the delay.
      Returns:
      The multiplier to use to calculate the delay
      Default:
      "1.0"
    • predicate

      Class<? extends RetryPredicate> predicate
      Returns the retry predicate class to use instead of includes() and excludes().
      Returns:
      The retry predicate class to use instead of includes() and excludes() (defaults to none)
      Default:
      io.micronaut.retry.annotation.DefaultRetryPredicate.class
    • capturedException

      Class<? extends Throwable> capturedException
      Returns the exception type that should be intercepted for retry handling.
      Returns:
      The exception type that should be intercepted for retry handling. Once an exception is captured, it is still evaluated by includes(), excludes(), or predicate() to decide whether to retry. Defaults to Exception.
      Default:
      java.lang.Exception.class
    • jitter

      Returns the jitter factor used to apply random deviation to retry delays.
      Returns:
      The jitter factor used to apply random deviation to retry delays
      Default:
      "0.0"