Class SimpleRetry<E extends Exception>
java.lang.Object
ubic.gemma.core.util.SimpleRetry<E>
-
Constructor Summary
ConstructorsConstructorDescriptionSimpleRetry(SimpleRetryPolicy retryPolicy, Class<E> exceptionClass, String logCategory) Create a new simply retry strategy. -
Method Summary
Modifier and TypeMethodDescription<T> Texecute(SimpleRetryCallable<T, E> callable, Object what) Execute the given callable with a retry strategy.
-
Constructor Details
-
SimpleRetry
Create a new simply retry strategy.- Parameters:
exceptionClass- the type of exception on which retry happenslogCategory- log category to use for retry-related messages
-
-
Method Details
-
execute
Execute the given callable with a retry strategy.- Parameters:
what- an object describing what is being retried, it's toString() will be used for logging- Throws:
E- the first exception to occur, all other will be included as suppressed viaThrowable.addSuppressed(Throwable).
-