Class RetryConfig

java.lang.Object
com.google.adk.workflow.RetryConfig

@Experimental public abstract class RetryConfig extends Object
How a node is retried when it fails. The builder initializes each property to its DEFAULT_ constant, except exceptions(), which starts unset.
  • Field Details

  • Constructor Details

    • RetryConfig

      public RetryConfig()
  • Method Details

    • maxAttempts

      public abstract int maxAttempts()
      Returns the maximum number of attempts, including the first, so 0 or 1 means no retry.
    • initialDelay

      public abstract Duration initialDelay()
      Returns the delay before the first retry.
    • maxDelay

      public abstract Duration maxDelay()
      Returns the ceiling on any single delay.
    • backoffFactor

      public abstract double backoffFactor()
      Returns the multiplier applied to the delay after each attempt.
    • jitter

      public abstract double jitter()
      Returns the randomness factor, not a duration: the delay is spread over delay * (1 +/- jitter). Zero removes randomness.
    • exceptions

      public abstract Optional<com.google.common.collect.ImmutableList<String>> exceptions()
      Returns the simple type names of the failures to retry on, matched exactly with no subclass match. When unset, any failure is retried; an empty list retries none.
    • builder

      public static RetryConfig.Builder builder()
    • toBuilder

      public abstract RetryConfig.Builder toBuilder()