Browse patterns / System architecture / A026
blue green deployment

Blue-green deployment

Release without downtime by running a matching green environment alongside blue and switching traffic after validation.

Recorded evidence 14/14Compare →Source
01 / UNDERSTAND

Structure and behavior

Follow the arrows step by step.

Prepare both environments, then switch traffic. Assess database change compatibility separately.

Expected benefits

Fast routing rollback, environment-by-environment comparison, and no mixed versions after cutover.

Trade-offs

Duplicate infrastructure costs, plus complexity in state synchronization and identity management.

Irreversible changes, such as destructive migrations, invalidate the rollback guarantee; avoid them or proceed with care.

02 / APPLY

Operations and adoption guide

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

When to use

Suitable for web or API services that need zero-downtime releases and fast rollback, regular Kubernetes cluster upgrades, and cloud migration cutovers.

Scenario

A Korean e-commerce company serving millions of users deploys its order API twice a month. It requires no downtime, rollback within 5 minutes, and payment data consistency. Blue handles current traffic while the new version is deployed to green and passes smoke, performance, and SLO gates. Switch routing, monitor metrics, and revert immediately to blue if anomalies appear.

Placement principles

  • Give blue and green identical application, configuration, and dependency setups
  • Switch traffic at the routing layer, such as a load balancer, API gateway, or service mesh
  • Use a forward- and backward-compatible database schema both versions can read and write
  • Specify whether sessions, caches, and external integrations are shared or environment-specific and how state is synchronized
  • Create and remove green as needed with IaC to control drift and cost.

On premises

Keep the source environment for a period to preserve rollback. Validate load balancer or DNS cutover and data migration compatibility beforehand, and manage configuration drift and resource costs of both environments through operating procedures.

03 / VERIFY

Evidence by criterion (14 total)

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

Definition and overviewEvidence available

Release without downtime by running a matching green environment alongside blue and switching traffic after validation.

runs two identical production environments simultaneously to achieve zero-downtime deployments and enable fast rollbacks

www.ibm.com original ↗

Problem addressedEvidence available

Reduces deployment downtime and the risk of prolonged recovery after failure, and enables fast rollback.

to achieve zero-downtime deployments and enable fast rollbacks.

www.ibm.com original ↗

Key components and resourcesEvidence available

Two identical production environments and a mechanism to route and switch traffic between them.

Blue/green environments also have a mechanism to route traffic between them.

developer.hashicorp.com original ↗

Data and asset placementEvidence available

For stateful assets such as databases, configure a single database or schema to be forward and backward compatible with both environments.

configure a single database for backward and forward compatibility.

docs.cloudfoundry.org original ↗

Typical use casesEvidence available

Deploy and validate the new version in the idle environment, then switch traffic for a zero-downtime release.

The current release is always deployed to the idle environment and traffic is switched to it after deployment completes, with no downtime.

cloud.ibm.com original ↗

Example scenarioEvidence available

When migrating from a source or on-premises environment to a new AKS cluster, roll back quickly to the source if problems occur.

I need rapid traffic rollback to the source if anything goes wrong after cutover.

learn.microsoft.com original ↗

When to avoid and caveatsEvidence available

Irreversible changes, such as destructive migrations, invalidate the rollback guarantee; avoid them or proceed with care.

Irreversible changes break the rollback promise outright.

abs.am original ↗

On premises: development, deployment, and operationsEvidence available

When cutting over an on-premises or source cluster or VM to a new environment, retain the source as a rollback path.

migrating workloads from a source cluster, VM estate, or on-premises environment into a new AKS cluster

learn.microsoft.com original ↗

Cloud: development, deployment, and operationsEvidence available

In managed Kubernetes or the cloud, validate the new version, then change routing to switch user traffic.

Once the new version is validated, a routing change switches user traffic to it.

learn.microsoft.com original ↗

Kubernetes: development, deployment, and operationsEvidence available

When upgrading a Kubernetes cluster such as EKS, create a second cluster, deploy and validate the app, and then switch.

we do a blue-green deployment, where we create a second cluster with the latest version of Amazon EKS and Istio.

aws.amazon.com original ↗

Incident responseEvidence available

After rollback or undo, revalidate the previous environment’s health and data integrity.

Re-validate old environment health and data integrity.

learn.microsoft.com original ↗

BenefitsEvidence available

Fast routing rollback, environment-by-environment comparison, and no mixed versions after cutover.

fast routing rollback; - clean environment-level comparison; - no mixed application versions after cutover

design.babushkai.com original ↗

Drawbacks and trade-offsEvidence available

Duplicate infrastructure costs, plus complexity in state synchronization and identity management.

near-double serving infrastructure during overlap; - state synchronization and identity complexity

design.babushkai.com original ↗

Representative tools and technologiesEvidence available

Cluster and service-mesh technologies such as Amazon EKS and Istio.

we create a second cluster with the latest version of Amazon EKS and Istio.

aws.amazon.com original ↗

Additional references (23)