Interface Retry


public interface Retry
Retry executor implementation
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static interface 
    Retry State implementation for manual retry execution handling
  • Method Summary

    Modifier and Type
    Method
    Description
    reactor.util.retry.Retry
     
     
    void
    retry(Runnable runnable)
     
    <T> T
    retry(Supplier<T> supplier)
     
    <T> T
    retry(Supplier<T> supplier, Supplier<T> fallback)
     
  • Method Details

    • asState

      @Nonnull Retry.RetryState asState()
      Returns:
      new Retry.RetryState
    • asReactor

      @Nonnull reactor.util.retry.Retry asReactor()
      Returns:
      new Retry implementation for Project Reactor retry handling
    • retry

      void retry(@Nonnull Runnable runnable) throws RetryExhaustedException
      Parameters:
      runnable - to execute for successful completion
      Throws:
      RetryExhaustedException - if exhausted all attempts
    • retry

      <T> T retry(@Nonnull Supplier<T> supplier) throws RetryExhaustedException
      Type Parameters:
      T - type of value
      Parameters:
      supplier - to use for value extraction
      Returns:
      value is succeeded
      Throws:
      RetryExhaustedException - if exhausted all attempts
    • retry

      <T> T retry(@Nonnull Supplier<T> supplier, Supplier<T> fallback)
      Type Parameters:
      T - type of value
      Parameters:
      supplier - to use for value extraction
      fallback - to use for value if failed to retrieve value from supplier
      Returns:
      value is succeeded