Package org.apache.iceberg.util
Class Tasks.Builder<I>
java.lang.Object
org.apache.iceberg.util.Tasks.Builder<I>
- Enclosing class:
- Tasks
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionabortWith
(Tasks.Task<I, ?> task) countAttempts
(Counter counter) exponentialBackoff
(long backoffMinSleepTimeMs, long backoffMaxSleepTimeMs, long backoffMaxRetryTimeMs, double backoffScaleFactor) noRetry()
onFailure
(Tasks.FailureTask<I, ?> task) onlyRetryOn
(Class<? extends Exception> exception) final Tasks.Builder<I>
onlyRetryOn
(Class<? extends Exception>... exceptions) retry
(int nTimes) revertWith
(Tasks.Task<I, ?> task) <E extends Exception>
booleanrun
(Tasks.Task<I, E> task, Class<E> exceptionClass) boolean
run
(Tasks.Task<I, RuntimeException> task) shouldRetryTest
(Predicate<Exception> shouldRetry) final Tasks.Builder<I>
stopRetryOn
(Class<? extends Exception>... exceptions) throwFailureWhenFinished
(boolean throwWhenFinished)
-
Constructor Details
-
Builder
-
-
Method Details
-
executeWith
-
onFailure
-
stopOnFailure
-
throwFailureWhenFinished
-
throwFailureWhenFinished
-
suppressFailureWhenFinished
-
revertWith
-
stopRevertsOnFailure
-
abortWith
-
stopAbortsOnFailure
-
stopRetryOn
-
shouldRetryTest
-
noRetry
-
retry
-
onlyRetryOn
-
onlyRetryOn
-
countAttempts
-
exponentialBackoff
public Tasks.Builder<I> exponentialBackoff(long backoffMinSleepTimeMs, long backoffMaxSleepTimeMs, long backoffMaxRetryTimeMs, double backoffScaleFactor) -
run
-
run
- Throws:
E extends Exception
-