Class BdkExponentialFunction

java.lang.Object
com.symphony.bdk.core.retry.util.BdkExponentialFunction

@API(status=INTERNAL) public class BdkExponentialFunction extends Object
Custom BdkExponentialFunction class to be used in Bdk Retry mechanism. The interval between 2 retries will be initiated by the value BdkRetryConfig#initialIntervalMillis. After each retry, this interval will be multiplied by BdkRetryConfig#multiplier. This interval will be limited by BdkRetryConfig#maxIntervalMillis, in means that, when this interval is greater than this value, it will not be multiplied any more and set to BdkRetryConfig#maxIntervalMillis.
  • Constructor Details

    • BdkExponentialFunction

      public BdkExponentialFunction()
  • Method Details

    • ofExponentialBackoff

      public static io.github.resilience4j.core.IntervalFunction ofExponentialBackoff(com.symphony.bdk.core.config.model.BdkRetryConfig retryConfig)
      Produce an interval function from given BdkRetryConfig.
      Parameters:
      retryConfig - given retry configuration.
      Returns:
      an IntervalFunction to be used in Retry mechanism.