Package 

Class FlakySafetyProviderSimpleImpl

    • Method Summary

      Modifier and Type Method Description
      <T extends Any> T flakySafely(Function0<T> action) Invokes the given action flaky safely.
      <T extends Any> T flakySafely(Long timeoutMs, Long intervalMs, Set<Class<Out Throwable>> allowedExceptions, String failureMessage, Function0<T> action) Invokes the given action flaky safely.
      • Methods inherited from class com.kaspersky.kaspresso.flakysafety.FlakySafetyProvider

        equals, hashCode, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • flakySafely

         <T extends Any> T flakySafely(Function0<T> action)

        Invokes the given action flaky safely.

        Parameters:
        action - the action to invoke.
      • flakySafely

         <T extends Any> T flakySafely(Long timeoutMs, Long intervalMs, Set<Class<Out Throwable>> allowedExceptions, String failureMessage, Function0<T> action)

        Invokes the given action flaky safely.

        Parameters:
        timeoutMs - the timeout during which attempts will be made.
        intervalMs - the interval at which attempts will be made.
        allowedExceptions - the set of exceptions, if caught, attempt will continue.
        failureMessage - the message to log on failure.
        action - the action to invoke.