How does the rolling update work?
A Rolling Update is initiated when changes are made to the Container Settings of your application, such as:- Updating the container image
- Changing the container name
- Modifying health check settings
Changes to endpoints do not trigger a Rolling Update. Endpoint changes are applied immediately without interrupting the running containers.
Practical example
Imagine you have an application deployed in 3 regions, each with 10 pods. If you update the container image:-
Iteration 1:
- Add 2 new pods (20% of 10) in each region.
- Wait until new pods are running and healthy.
- Remove 2 old pods in each region.
-
Iterations 2–5:
- Repeat the above steps until all pods are updated.
Applications with persistent volumes
When your application uses persistent volumes, the rolling update process is adjusted to prevent data corruption. Rather than starting new pods before removing old ones, existing pods are shut down first to fully unmount their volumes before new pods are started.Practical example
Imagine you have an application deployed in 3 regions, each with 10 pods, and each pod has a persistent volume attached. If you update the container image:-
Iteration 1:
- Remove 2 old pods (20% of 10) in each region and wait for their volumes to fully unmount.
- Start 2 new pods in each region and wait until they are running and healthy.
-
Iterations 2–5:
- Repeat the above steps until all pods are updated.