Browse patterns / System architecture / A027
canary deployment

Canary deployment

A progressive release that deploys changes to part of a service for a limited period and evaluates the results.

Recorded evidence 14/14Compare →Source
01 / UNDERSTAND

Structure and behavior

Follow the arrows step by step.

Validate the new version with a small share of traffic and expand in stages.

Expected benefits

Improves application reliability and reduces deployment risk.

Trade-offs

Rolling back during peak traffic can cause temporary service degradation while the stable ReplicaSet scales up.

Avoid or proceed carefully for trivial fixes, inadequate observability, or complex or unsafe rollback paths.

02 / APPLY

Operations and adoption guide

Synthesis, distinct from items backed by source excerpts. Validate before applying in production.

When to use

Use a small portion of real traffic to validate high-impact changes to critical user flows, payments or monetization, as well as stateful services, external integrations, and schema or protocol changes.

Scenario

An e-commerce platform with 10 million monthly active users replaces its order and payment API. Send 1% of traffic to canary pods and watch errors, latency, and payment failures. If SLOs hold, progress to 5% → 25% → 100%. If anomalies appear, immediately reduce the canary share to zero and restore the stable version, keeping enough stable capacity throughout rollback.

Placement principles

  • Run stable and canary workloads in parallel and identify them with track/version labels
  • Use load-balancer, ingress, or service-mesh weights to send a small share to the canary
  • Maintain enough stable ReplicaSet or pod capacity throughout the canary so rollback can reroute traffic immediately
  • Keep schemas, caches, and configuration compatible with the older version for rollback
  • Run the same observability agents and verification tools for both versions.

On premises

On premises, control the canary share using load-balancer or ingress weights and separate server pools. Keep stable capacity available, then test and expand the canary share. Without managed cloud routing, automate monitoring, verification, and rollback procedures in advance.

03 / VERIFY

Evidence by criterion (14 total)

Evidence availability at the time of research. Assess source accuracy and currency separately.

Definition and overviewEvidence available

A progressive release that deploys changes to part of a service for a limited period and evaluates the results.

We define canarying as a partial and time-limited deployment of a change in a service and its evaluation.

sre.google original ↗

Problem addressedEvidence available

Test the new version with real production traffic before releasing it everywhere.

Test the new version with real production traffic

kubernetes.io original ↗

Key components and resourcesEvidence available

Run stable and canary versions side by side, distinguish them with track labels or equivalent, and distribute traffic.

The stable release uses `track: stable`, and the canary release uses `track: canary`.

kubernetes.io original ↗

Data and asset placementEvidence available

Retain stable ReplicaSet capacity throughout the canary and route a separate share to the new version.

keep the stable ReplicaSet at full size for the whole canary

abd-ulbasit.github.io original ↗

Typical use casesEvidence available

Use for payments or other critical user flows, stateful services, high-risk external integrations, and major schema or protocol changes.

Changes that impact critical user flows or monetization.

www.cloudopsnow.in original ↗

Example scenarioEvidence available

Example: in a staged Kubernetes release, route 20% of stateless API traffic through a canary selector.

# Phase 1: Stateless services (20% traffic) kubectl patch service api-service -p '{"spec":{"selector":{"version":"canary"}}}'

learn.microsoft.com original ↗

When to avoid and caveatsEvidence available

Avoid or proceed carefully for trivial fixes, inadequate observability, or complex or unsafe rollback paths.

When NOT to use / overuse: - For trivial fixes that increase release friction. - When observability is insufficient to detect failures.

www.cloudopsnow.in original ↗

On premises: development, deployment, and operationsEvidence available

Customer on-premises data centers can also deploy and operate Kubernetes-based services.

our newest service offering: Bitmovin Managed On-Premise encoding

kubernetes.io original ↗

Cloud: development, deployment, and operationsEvidence available

Run in parallel with the existing production version without downtime and control the traffic split.

Canary release : Deploys a new release in parallel with the original production environment (similar to Blue-Green), with no downtime.

cloud.ibm.com original ↗

Kubernetes: development, deployment, and operationsEvidence available

In Kubernetes, deploy a canary alongside the stable version and compare them to decide whether to promote or reject the canary.

A canary deployment strategy deploys new versions of an application next to stable, production versions.

learn.microsoft.com original ↗

Incident responseEvidence available

If an alert indicates a health metric affecting users, stop the rollout immediately and investigate.

the rollout should immediately halt and an investigation into the cause of the alert should be performed

learn.microsoft.com original ↗

BenefitsEvidence available

Improves application reliability and reduces deployment risk.

Blue/green, canary, and rolling deployments all improve application reliability and reduce risk.

developer.hashicorp.com original ↗

Drawbacks and trade-offsEvidence available

Rolling back during peak traffic can cause temporary service degradation while the stable ReplicaSet scales up.

Possible brown-out as the stable RS scales.

abd-ulbasit.github.io original ↗

Representative tools and technologiesEvidence available

Spinnaker can poll a deployment verification API to evaluate canary health against thresholds.

one Spinnaker node on the stack that actually queries this API and polls it for duration

www.infoq.com original ↗

Additional references (21)