Package cz.xtf.core.waiting.failfast
Class FailFastBuilder
- java.lang.Object
-
- cz.xtf.core.waiting.failfast.FailFastBuilder
-
public class FailFastBuilder extends Object
The class provides support to createFailFastCheck{@see MultipleFailFastChecksHandler} that checks if a waiter should fail due to an error state of cluster. The function is supposed to be called by aWaiter. If it returns true, the waiter should throw an exception.Example of use:
FailFastBuilder .ofTestAndBuildNamespace() .events() .after(EventHelper.timeOfLastEventBMOrTestNamespaceOrEpoch()) .ofNames("my-app.*") .ofMessages("Failed.*") .atLeasOneExists() .build()You can create more checks for events and every one of them will be checked. If one of them returns true, the whole fail fast function returns true.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description FailFastCheckbuild()EventFailFastCheckBuilderevents()static FailFastBuilderofOpenShifts(OpenShift... openShifts)static FailFastBuilderofTestAndBuildNamespace()
-
-
-
Method Detail
-
ofTestAndBuildNamespace
public static FailFastBuilder ofTestAndBuildNamespace()
-
ofOpenShifts
public static FailFastBuilder ofOpenShifts(OpenShift... openShifts)
-
events
public EventFailFastCheckBuilder events()
-
build
public FailFastCheck build()
-
-