Class ExecutorCircuitBreaker

java.lang.Object
io.openlineage.client.circuitBreaker.ExecutorCircuitBreaker
All Implemented Interfaces:
CircuitBreaker
Direct Known Subclasses:
JavaRuntimeCircuitBreaker, NoOpCircuitBreaker, SimpleMemoryCircuitBreaker, StaticCircuitBreaker

public abstract class ExecutorCircuitBreaker extends Object implements CircuitBreaker
  • Field Details

  • Constructor Details

    • ExecutorCircuitBreaker

      public ExecutorCircuitBreaker(Integer circuitCheckIntervalInMillis)
    • ExecutorCircuitBreaker

      public ExecutorCircuitBreaker(Integer circuitCheckIntervalInMillis, Duration timeout)
  • Method Details

    • run

      public <T> T run(Callable<T> callable)
      Specified by:
      run in interface CircuitBreaker
      Type Parameters:
      T - callable generic type
      Parameters:
      callable - The callable to be run
      Returns:
      result of callable
    • getCheckIntervalMillis

      public int getCheckIntervalMillis()
      Specified by:
      getCheckIntervalMillis in interface CircuitBreaker
    • getTimeout

      public Optional<Duration> getTimeout()
    • isPercentageValueValid

      protected boolean isPercentageValueValid(Integer value)