Class RetryUtils

java.lang.Object
run.halo.gradle.utils.RetryUtils

public class RetryUtils extends Object
  • Constructor Details

    • RetryUtils

      public RetryUtils()
  • Method Details

    • withRetry

      public static void withRetry(int maxTimes, long baseSleepMillis, RetryUtils.CallToRetry call)
      Retry the given call. We use a function baseSleepMillis * Math.pow(retryTimes, 2) to calculate the sleep time