Blue green deployment and Rolling Update

Sudha Subramaniam
2 min readJun 8, 2024

Why different types of deployment strategies exist?

To minimize downtime of the application when deploymenting new versions and fixes

Blue Green deployment

Blue — Current Version of Application which is running and serving the traffic at the moment

Green -New version of Application which is running and not serving the traffic at the moment

Blue green — both blue (v1) and green(v2) is running in parallel (but green is not serving the traffic) -need to update the service to point to v2.

It provides zero down time and if green did not work properly then there is a option to switch back to blue but maintaining 2 environments which will double infrastructure resources.

Rolling Update

Rolling update is the default deployment strategy in Kubernetes.

1 new pod will get created with new version and added to old deployment and replaces old pod, similarly one by one all old (at one point in time there will be one extra pod will be there apart from replica set -maxSurge ) pods will be replaced with new pods And Service update not required as new deployment is not created

At any given time either old or new pod will be available to serve traffic which ensures zero downtime. And it gradaully replaces old pod with new ones. And rollback can be done based on rollout history -rollout undo deploy deploymentname — to-revision=1

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

No responses yet

Write a response