The control loop pattern has the following problem, solution, and solution requirements.
Problem
In a system landscape with a large number of microservice instances spread out over a number of servers, it is very difficult to manually detect and correct problems such as crashed or hung microservice instances.
Solution
Add a new component, a control loop, to the system landscape. This process is illustrated as follows:
Solution requirements
The control loop will constantly observe the actual state of the system landscape, comparing it with a desired state, as specified by the operators. If the two states differ, it will take actions to make the actual state equal to the desired state.
Implementation notes: In the world of containers, a container orchestrator such as Kubernetes is typically used to implement this pattern. We will learn more about Kubernetes in Chapter 15, Introduction to Kubernetes.