Interface FeedClient.CircuitBreaker

Enclosing interface:
FeedClient

public static interface FeedClient.CircuitBreaker
Allows slowing down or halting completely operations against the configured endpoint on high failure rates.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static enum 
     
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    A circuit breaker which is always closed.
  • Method Summary

    Modifier and Type
    Method
    Description
    default void
    Called by the client whenever an error HTTP response is received.
    default void
    Called by the client whenever an exception occurs trying to obtain a HTTP response.
    The current state of the circuit breaker.
    default void
    Called by the client whenever a successful response is obtained.
  • Field Details

  • Method Details

    • success

      default void success()
      Called by the client whenever a successful response is obtained.
    • failure

      default void failure(HttpResponse response)
      Called by the client whenever an error HTTP response is received.
    • failure

      default void failure(Throwable cause)
      Called by the client whenever an exception occurs trying to obtain a HTTP response.
    • state

      The current state of the circuit breaker.