Class Exponential

java.lang.Object
software.amazon.cloudformation.proxy.delay.Exponential
All Implemented Interfaces:
Delay

public class Exponential
extends java.lang.Object
Exponential, provides waves starting with minimum delay of AbstractDelay.timeout is exceeded
  • Nested Class Summary

    Nested Classes
    Modifier and Type Class Description
    static class  Exponential.Builder  
  • Method Summary

    Modifier and Type Method Description
    java.time.Duration nextDelay​(int attempt)
    Returns the new delay amount to stabilize as defined by Duration time.
    static Exponential.Builder of()  

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • of

      public static Exponential.Builder of()
    • nextDelay

      public java.time.Duration nextDelay​(int attempt)
      Description copied from interface: Delay
      Returns the new delay amount to stabilize as defined by Duration time. This returns -1 to indicate that we are done with delays from this instance Different implementations can return different values
      Parameters:
      attempt - , starts with 1
      Returns:
      the next amount to wait for or Duration.ZERO to indicate delay is complete