Package com.intershop.gradle.icm.utils
Interface Probe
-
- All Implemented Interfaces:
public interface ProbeDefines a probe: execute a certain action in a defines retry interval until it is a success or the retry timeout is reached.
-
-
Method Summary
Modifier and Type Method Description abstract Booleanexecute()Executes this probe abstract ProbewithRetryInterval(Duration interval)Sets the retry interval abstract ProbewithRetryTimeout(Duration timeout)Sets the retry timeout abstract ProbeonSuccess(Function1<Unit, Unit> onSuccess)Assigns a callback that is executed when this Probe finishes with a success. abstract ProbeonFailure(Function1<Unit, Unit> onFailure)Assigns a callback that is executed when this Probe finishes with a failure. -
-
Method Detail
-
withRetryInterval
abstract Probe withRetryInterval(Duration interval)
Sets the retry interval
- Returns:
this Probe
-
withRetryTimeout
abstract Probe withRetryTimeout(Duration timeout)
Sets the retry timeout
- Returns:
this Probe
-
onSuccess
abstract Probe onSuccess(Function1<Unit, Unit> onSuccess)
Assigns a callback that is executed when this Probe finishes with a success. The callback is not called for each internal retry attempt.
-
-
-
-