When we are thinking about the resiliency of the application, we should try to answer the following questions: Can the application handle failure conditions? If one component of the application fails, does it bring down the whole application? Is there a single point of failure in the application?
Let's look at some patterns that will help us to make our application resilient.
This is an important pattern to implement both resilience and responsiveness in the system. Often, when a service fails in a system, it impacts other services as well. For example, service X calls service Y in the system to get or update some data. If service Y is unresponsive for some reason, our service X will make a call to service Y, wait for it to timeout, and then fail itself. Think of a scenario where service X itself is called up by another service P, and so on. We are looking at a cascading failure here, which will eventually bring down the whole system.
The circuit...