Annotation Type Retryable


@Target(METHOD) @Retention(RUNTIME) public @interface Retryable
Indicates that a method is to be retried if some exception occurs during its execution
  • Required Element Summary

    Required Elements
    Modifier and Type
    Required Element
    Description
    Class<? extends Throwable>[]
     
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    int
     
  • Element Details

    • exceptions

      Class<? extends Throwable>[] exceptions
      Returns:
      Array of exceptions that indicate that the method can be retried
    • times

      int times
      Returns:
      Maximum number of retries to do, anything above this and the exception is just propagated
      Default:
      1