Class MultiLevelCacheConfigurationProperties.CircuitBreakerProperties

java.lang.Object
io.github.suppie.spring.cache.MultiLevelCacheConfigurationProperties.CircuitBreakerProperties
Enclosing class:
MultiLevelCacheConfigurationProperties

public static class MultiLevelCacheConfigurationProperties.CircuitBreakerProperties extends Object
Circuit breaker just records calls to Redis - it does not time out them.

To simplify defaults, we rely on four core properties:

  • failureRateThreshold
  • slowCallRateThreshold
  • slowCallDurationThreshold
  • slidingWindowType
To compute appropriate values for your properties - use your slow calls as a baseline and consider a sliding window type:
  • Assuming that call is considered to be slow after 250ms
  • Then in 1 second we should be able to process more than 4 calls
  • If sliding window is count based then permittedNumberOfCallsInHalfOpenState should be 4, minimumNumberOfCalls is 2 and slidingWindowSize is 8 (calls == 2 seconds)
  • If sliding window is time based then permittedNumberOfCallsInHalfOpenState should be 4, minimumNumberOfCalls is 2 and slidingWindowSize is 2 (seconds == 8 seconds)
  • Constructor Details

    • CircuitBreakerProperties

      public CircuitBreakerProperties()