52
Views
3
Comments
[Circuit Breaker] Implementing Circuit Breaker Pattern when there is end point authentication
Question
circuit-breaker
Service icon
Forge asset by Carlos Sousa

Hi,

How does the Circuit Breaker component work when there is End point Authentication as I see that there is no way I can pass Authentication to End point URL input parameter to Circuit Breaker public methods.

2021-02-18 12-29-06
António Pereira
Champion

Hi Ravi,

I don't know if I understood your doubt clearly, but the goal of this component is not to be a wrapper when you call an API.  This component is just a set of actions that you use around your calls to APIs in your modules, as in this screenshot:

The EndpointKey input is just a key to associate to a JSON value. The authentication here or any other API characteristic is not relevant.


Hope it helps. Cheers,

António Pereira

2018-05-31 18-44-19
Ravi Vakkalanka

Hi Antonio,

Thank you for your reply. 

If Endpointkey input is just a key, then how will the circuit breaker decide when to close the circuit again after it is open ? 

Thanks

Ravi

2018-06-12 08-51-11
Carlos Sousa
Staff

Essentially the circuit breaker logic checks temporarily closes the circuit periodically to check if the API is already working.

These mechanism ensures that the circuit breaker won't open forever.

Carlos


Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.