Class Policies

java.lang.Object
com.qtsurfer.api.sdk.internal.Policies

public final class Policies extends Object
Factory helpers that build Failsafe policies shared by every workflow stage.
  • Method Details

    • stagePoller

      public static <T> dev.failsafe.FailsafeExecutor<T> stagePoller(Duration pollInterval, Duration maxPollInterval, Duration stageTimeout, Predicate<T> retryWhile)
      Build a FailsafeExecutor that polls fn with exponential backoff while the result matches retryWhile (expected to be an StatusNormalizer.Normalized.IN_PROGRESS check). Exceptions are never retried — they propagate so the caller can map them to the appropriate QTSError subclass.