Package org.apache.solr.common.util
Class RetryUtil
- java.lang.Object
-
- org.apache.solr.common.util.RetryUtil
-
public class RetryUtil extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
RetryUtil.BooleanRetryCmd
static interface
RetryUtil.RetryCmd
-
Constructor Summary
Constructors Constructor Description RetryUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
retryOnBoolean(long timeoutms, long intervalms, RetryUtil.BooleanRetryCmd cmd)
static void
retryOnException(Class<? extends Exception> clazz, long timeoutms, long intervalms, RetryUtil.RetryCmd cmd)
static void
retryOnException(Set<Class<? extends Exception>> classes, long timeoutms, long intervalms, RetryUtil.RetryCmd cmd)
static void
retryUntil(String errorMessage, int retries, long pauseTime, TimeUnit pauseUnit, RetryUtil.BooleanRetryCmd cmd)
-
-
-
Method Detail
-
retryOnException
public static void retryOnException(Class<? extends Exception> clazz, long timeoutms, long intervalms, RetryUtil.RetryCmd cmd) throws Exception
- Throws:
Exception
-
retryOnException
public static void retryOnException(Set<Class<? extends Exception>> classes, long timeoutms, long intervalms, RetryUtil.RetryCmd cmd) throws Exception
- Throws:
Exception
-
retryUntil
public static void retryUntil(String errorMessage, int retries, long pauseTime, TimeUnit pauseUnit, RetryUtil.BooleanRetryCmd cmd) throws InterruptedException
- Throws:
InterruptedException
-
retryOnBoolean
public static void retryOnBoolean(long timeoutms, long intervalms, RetryUtil.BooleanRetryCmd cmd)
-
-