Class LockOptions.ExponentialBackOff

    • Constructor Detail

      • ExponentialBackOff

        public ExponentialBackOff()
    • Method Detail

      • maxDelay

        public LockOptions.ExponentialBackOff maxDelay(long maxDelay)
        Sets max back off delay.

        Default is 128

        Parameters:
        maxDelay - - max sleep period. Has to be positive
        Returns:
        ExponentialBackOffOptions instance
      • getMaxDelay

        public long getMaxDelay()
      • initialDelay

        public LockOptions.ExponentialBackOff initialDelay(long initialDelay)
        Sets initial back off delay.

        Default is 1

        Parameters:
        initialDelay - - initial sleep period. Has to be positive
        Returns:
        ExponentialBackOffOptions instance
      • getInitialDelay

        public long getInitialDelay()
      • multiplier

        public LockOptions.ExponentialBackOff multiplier(int multiplier)
        Sets back off delay multiplier.

        Default is 2

        Parameters:
        multiplier - - sleep period multiplier. Has to be positive
        Returns:
        ExponentialBackOffOptions instance
      • getMultiplier

        public int getMultiplier()