☸️ Kubernetes Deployments vs. Argo Rollouts: How Traffic Really Switches Between Old and New Versions
Kubernetes Deployments vs. Argo Rollouts: How Traffic Really Switches Between Old and New Versions
When I first started learning Kubernetes deployments, I understood the concepts of Rolling Update, Blue-Green, and Canary. But one question kept bothering me:
How does Kubernetes actually switch users from the old version to the new version?
Does it change the Service?
Does it move traffic?
Does it kill old pods first?
After digging into Kubernetes and Argo Rollouts, I realized that understanding ReplicaSets, Services, and readiness probes makes everything much easier.
Let's walk through it step by step.
Standard Kubernetes Deployment
A normal Kubernetes deployment uses a Deployment resource. kind: Deployment
The Deployment controller is responsible for updating your application.
Suppose your application is currently running Version 1.
Users
│
Kubernetes Service
│
ReplicaSet (Version 1)
├── Pod
├── Pod
└── Pod
The Service sends requests to every Ready pod that matches its selector.
For example:
selector:
app: box-api
The Service doesn't know anything about application versions. It simply routes traffic to matching, healthy pods.
What Happens When You Deploy a New Version?
Now imagine changing the image from:
image: box-api:v1
to
image: box-api:v2
Kubernetes notices that the pod template has changed.
Instead of modifying existing pods, it creates a new ReplicaSet- ReplicaSet v1 , ReplicaSet v2
Both ReplicaSets temporarily exist at the same time.
Service
│
┌─────────┴─────────┐
│ │
v1 Pods v2 Pods
This surprises many people the first time they learn Kubernetes.
The Service doesn't switch between versions.
Instead, it sends traffic to all Ready pods, regardless of which ReplicaSet they belong to.
How Kubernetes Performs a Rolling Update
The Deployment strategy controls the rollout.
strategy:
type: RollingUpdate
rollingUpdate:
maxSurge: 1
maxUnavailable: 0
These two settings are extremely important.
maxSurge
maxSurge tells Kubernetes how many extra pods it may create during a deployment.
Suppose you normally run three replicas.
Initially:
v1
v1
v1
With maxSurge: 1, Kubernetes first creates one additional Version 2 pod.
v1
v1
v1
v2 (Starting)
Notice that it doesn't immediately remove an old pod.
Readiness Probe
Before the new pod receives production traffic, Kubernetes waits for the readiness probe to succeed.
Pod Starts
│
Readiness Probe
│
Ready?
If the probe fails:
The pod stays out of Service.
Users continue using the old pods.
If the probe succeeds:
Kubernetes adds the pod to the Service endpoints.
Only then does Kubernetes remove one old pod.
v1
v1
v2
The process repeats until every Version 1 pod has been replaced.
Can This Still Produce HTTP 500 Errors?
Yes.
Even if Kubernetes performs a perfect rolling update, users can still receive errors.
Some common causes include:
The readiness probe reports success too early.
The application contains a bug.
Database migrations are not backward compatible.
The application shuts down before finishing requests.
External dependencies fail.
This is because Kubernetes only knows whether a pod is Ready.
It has no idea whether your application is actually behaving correctly.
Enter Argo Rollouts
Argo Rollouts replaces the standard Deployment with a Rollout resource.
kind: Rollout
Instead of only supporting Rolling Updates, it introduces advanced deployment strategies such as:
Blue-Green
Canary
The biggest difference is that Argo gives you much finer control over when and how production traffic moves to the new version.
Blue-Green Deployment
Blue-Green is a deployment strategy where two versions of the application exist at the same time:
Blue = Current production version
Green = New version being deployed
Argo Rollouts typically manages this using two Kubernetes Services:
Active Service – serves production traffic.
Preview Service – exposes the new version for testing before it reaches production.
Initial State
Production users access Version 1 through the Active Service.
Users
│
Active Service
│
Version 1 Pods
Deploying Version 2
When a new version is deployed, Argo Rollouts creates a new ReplicaSet for Version 2 and exposes it through the Preview Service.
Users
│
Active Service
│
Version 1 Pods
Tester
│
Preview Service
│
Version 2 Pods
Production users continue using Version 1.
Only testers or automated validation systems access Version 2 through the Preview Service.
This allows engineers to verify that the new release behaves correctly before exposing it to production traffic.
Promotion
Once validation is complete, Argo promotes the rollout by switching the Active Service.
Users
│
Active Service
│
Version 2 Pods
Unlike a standard Kubernetes rolling deployment, Argo does not gradually replace old pods with new pods.
Instead, it changes the Active Service selector so production traffic is routed to the new ReplicaSet.
From the users' perspective, traffic changes like this:
Before Promotion 100% → Version 1
After Promotion 100% → Version 2
What Happens During Automatic Promotion?
If the rollout is configured with:
strategy:
blueGreen:
autoPromotionEnabled: true
Argo Rollouts waits until the new ReplicaSet is healthy. Specifically, it waits for Kubernetes to report that the new pods are Ready.
If all pods become Ready, Argo automatically switches production traffic from Version 1 to Version 2.
What If the New Version Has an Application Bug?
This is an important distinction.
Imagine the following scenario: Pods start successfully , Readiness probe passes , Containers remain healthy , Every /checkout request returns HTTP 500 ......
͢͢͢From Kubernetes' perspective:
Pods = Ready
ReplicaSet = Healthy
From Argo Rollouts' perspective:
Deployment = Healthy
Since Kubernetes reports healthy pods, Argo has no reason to stop the rollout.
It automatically promotes Version 2.
Users
│
Active Service
│
Version 2 Pods (Returning HTTP 500)
Now every production user is using the broken version.
By default, Blue-Green does not automatically detect application-level failures such as:
HTTP 500 responses
Broken business logic
Failed checkout flows
Database query failures
Incorrect API responses
It only knows whether Kubernetes considers the new pods healthy.
When Does Blue-Green Stop Automatically?
Blue-Green automatically prevents promotion only when Kubernetes reports infrastructure or pod failures.
Examples include: ImagePullBackOff, CrashLoopBackOff, Readiness probe failure, Pods never becoming Ready
Flow:
Deploy Version 2
│
Pods become Ready?
│
No ─────────► Promotion never happens
│
Yes
│
Automatic Promotion
In these cases, production traffic continues using Version 1.
Can Blue-Green Automatically Roll Back?
Yes...but only if application health is monitored. Argo Rollouts supports AnalysisRuns, which can integrate with monitoring systems such as Datadog, Prometheus, or CloudWatch.
Example flow:
Deploy Version 2
│
Pods Ready
│
Promote
│
Run Analysis
│
High HTTP 5xx Rate?
│
Yes ─────────► Abort or Roll Back
Without an AnalysisRun or manual validation, Argo only evaluates pod health, not application health.
Canary Deployment
Canary deployments move traffic gradually. Instead of switching everyone at once, traffic shifts in stages.
90% → Version 1, 10% → Version 2
Later:
75% → Version 1, 25% → Version 2
Eventually: 100% → Version 2
This reduces deployment risk because only a small portion of users initially receives the new release.
Does Canary Automatically Detect HTTP 500 Errors?
Not by itself.
This is one of the biggest misconceptions about Canary deployments.
Suppose the rollout is fully automatic.
10%
↓
25%
↓
50%
↓
100%
If there is: No Datadog, No Prometheus, No CloudWatch analysis, No AnalysisRun, No manual pause
Argo Rollouts has no way to know whether the application is returning HTTP 500 responses.
As long as the pods are: Running, Ready
Argo assumes the deployment is healthy.
What Can Argo Detect Automatically?
Argo can detect infrastructure and pod-level failures.
Examples include: CrashLoopBackOff, ImagePullBackOff, Readiness probe failures, Pods that never become Ready
In those cases, the rollout stops because Kubernetes reports that the new ReplicaSet isn't healthy.
What Argo Cannot Detect Without Monitoring
Argo cannot automatically detect: HTTP 500 responses, Checkout failures, Business logic bugs, Incorrect API responses, Database query failures
Those require application-level monitoring or manual validation.
Key Takeaways
The most important lesson I learned is that deployment strategy and application health are two different problems.
A standard Kubernetes Deployment focuses on safely replacing pods.
Blue-Green focuses on validating a complete new environment before switching everyone.
Canary focuses on gradually exposing production traffic to the new version.
Neither strategy magically fixes application bugs or HTTP 500 errors.
A successful deployment combines:
Proper readiness probes
Graceful shutdown
Backward-compatible database changes
Safe rollout strategy
Monitoring and observability
Argo Rollouts reduces deployment risk.....but the application still has to be healthy.
Final Thoughts
Understanding how Kubernetes actually replaces pods makes Blue-Green and Canary much easier to understand.
Once you know that Deployments manage ReplicaSets, Services route to Ready pods, and Argo Rollouts controls traffic progression instead of simply replacing pods, advanced deployment strategies become much less mysterious.
In my next post, I'll dive deeper into how Argo Rollouts works internally with ReplicaSets, Services, AWS ALB, traffic routing, promotion, and rollback.