Class MultipleOf

java.lang.Object
software.amazon.cloudformation.proxy.delay.Constant
software.amazon.cloudformation.proxy.delay.MultipleOf
All Implemented Interfaces:
Delay
Direct Known Subclasses:
ShiftByMultipleOf

public class MultipleOf extends Constant
Provides constant fixed delay seconds which is a multiple of the delay for each attempt until AbstractDelay.timeout has been reached. After which it will return Duration.ZERO
  • Method Details

    • multipleOf

      public static MultipleOf.Builder multipleOf()
    • nextDelay

      public 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
      Specified by:
      nextDelay in interface Delay
      Overrides:
      nextDelay in class Constant
      Parameters:
      attempt - , starts with 1
      Returns:
      the next amount to wait for or Duration.ZERO to indicate delay is complete