Kubernetes doesn’t only run applications; it keeps them running. It does this with a "desired state" approach: you declare a target, such as "run three replicas of this application", and the platform keeps bringing the actual state back to that target.
In production, this comes down to a few mechanisms:
Health checks
The application is probed at set intervals; a replica that doesn’t respond is taken out of traffic and restarted.
Restart after failure
When a physical server fails, its replicas start again on healthy servers; if the target is three replicas, three keep running.
Resource limits
A memory leak in one application can’t affect its neighbors; a replica that exceeds its limit is restarted.
Scaling with load
When traffic rises, the replica count grows automatically within set limits, and falls when traffic drops.
These mechanisms have to be set up correctly: a badly defined health check can keep restarting a healthy application. With the Managed Kubernetes service, these settings are delivered with the values used in production.
Related service:
Managed Kubernetes