Questions tagged [circuit-breaker]

Circuit breaker is a design pattern in modern software development. Circuit breaker is used to detect failures and encapsulates logic of preventing a failure to reoccur constantly (during maintenance, temporary external system failure or unexpected system difficulties).

385 questions
6
votes
1 answer

Difference between sliding window size and minimum number of calls

I am new to circuit breakers and have recently implemented them in one of my services. I was going through the documentation Resilience 4J official documentation and found two properties that we can configure for circuit…
6
votes
1 answer

Can Envoy Proxy be used to wrap a third-party API?

I'm looking for to utilize a more mainstream and language-agnostic API proxy/wrapper for implementing common patterns (eg, circuit breaker, health checks, etc.) and tracking stats for API calls. However, this wrapper would be for remote third-party…
Rob Olmos
  • 2,372
  • 15
  • 24
6
votes
3 answers

What is advantage of circuit breaker design pattern in API architecture?

So sorry if this question is not fit for SO. But I tried looking lot for answer. I was studying Circuit Breaker design pattern, As I understand its used for making you API fault tolerance. Now what I am confuse is, Let say I have API which calls…
VedantK
  • 9,728
  • 7
  • 66
  • 71
6
votes
3 answers

Circuit breaker with kafka consumer

Is there a way to implement a circuit breaker pattern with Spring Kafka based consumer . I am wondering while implementing my Spring kafka consumer is it possible to stop consuming records if there is a failure to process the data based on some…
Joydeep
  • 401
  • 2
  • 6
  • 15
6
votes
3 answers

Concatenate many Future[Seq] into one Future[Seq]

Without Future, that's how I combine all smaller Seq into one big Seq with a flatmap category.getCategoryUrlKey(id: Int):Seq[Meta] // main method val appDomains: Seq[Int] val categories:Seq[Meta] =…
Raymond Chenon
  • 11,482
  • 15
  • 77
  • 110
6
votes
1 answer

Hystrix circuit breaker with business exceptions

I have observed that Hystrix treats all exceptions coming out of commands as failures for circuit breaking purposes. It includes exceptions which are thrown from command run () method and created by Hystrix itself, e.g. HystrixTimeoutException. But…
Max Myslyvtsev
  • 493
  • 5
  • 14
6
votes
1 answer

Significant terms causes a CircuitBreakingException

I've got a mid-size elasticsearch index (1.46T or ~1e8 docs). It's running on 4 servers which each have 64GB Ram split evenly between elastic and the OS (for caching). I want to try out the new "Significant terms" aggregation so I fired off the…
Basic
  • 26,321
  • 24
  • 115
  • 201
5
votes
1 answer

What does it mean to enable CB when a rollback is false?

what is the difference? 1. --deployment-configuration "deploymentCircuitBreaker={enable=true,rollback=false}" --deployment-configuration "deploymentCircuitBreaker={enable=false,rollback=false}" What does it mean to enable CB when a rollback is…
Jay
  • 397
  • 1
  • 5
  • 19
5
votes
1 answer

What is the best order to apply multiple Polly policies?

The order in which Polly policies are encapsulated change the final result. Which is the best order if I want to use the following policies? This is the best order I could think of: the retries should be submitted to the bulkhead limits, and the…
5
votes
1 answer

Webflux WebClient retry and Spring Cloud Circuit Breaker Resilience4J Retry pattern walk into a bar

Would like to ask a question about two technologies. We first started with an application that has to call other third parties rest API, hence, we used the Webflux WebClient in our SpringBoot Webflux project. So far so good, we had a successful app…
PatPanda
  • 3,644
  • 9
  • 58
  • 154
5
votes
1 answer

Why use Circuit Breaker and Bulkhead when working with Spring Reactor?

Please help me find reasons why Circuit breaker and Bulkhead patterns are useful in a Spring Reactor application. Since operations will be non-blocking in Reactor and those two patterns aim at saving potential hit to resources (mostly threads), in…
LIvanov
  • 1,126
  • 12
  • 30
5
votes
2 answers

Call is not going to fallback method of Resilience4 Circuit breaker

I am using Resilience4j Circuit breaker version: '1.4.0 with Spring boot version 2.0.6 and my problem is - fallback method is not working. the call is not going to the fallback method. Below is my code…
vbvT
  • 71
  • 1
  • 8
5
votes
0 answers

Istio Circuit Breaker Fallback

I'm exploring Istio's circuit breaker and wan't to setup fallback methods if the circuit trips. I have a few Spring boot applications that are deployed on kubernetes and with Istio's circuit breaking defined in DestinationRule. I can see that my…
ViV
  • 1,998
  • 8
  • 27
  • 54
5
votes
2 answers

Proper way to handle multiple services with polly circuit breaker

I have an application where we communicate with hundreds of HTTPs endpoints. The application is a proxy of sorts. When testing with polly, I've noticed that if one endpoint, say api.endpoint1.com fails, the calls to api.endpoint2.com and…
5
votes
1 answer

How to combine Retryable and CircuitBreaker together in Spring?

Spring's @Retryable annotation will retry three times (default) and fallback to the @Recovery method. @CircuitBreaker however, will retry once and fall back when the state is closed. I want to combine these two: when the circuit breaker state is…
Zebing Lin
  • 371
  • 4
  • 6
1
2
3
25 26