EMZETT.
Login

Blue-green and canary deployment

In short: These are methods for rolling out new program versions without downtime and going back immediately if there are problems.

In more detail: In blue-green deployment two complete environments run. The new one (“green”) is tested, then traffic is switched over. If there are problems, you switch back to “blue”. In canary deployment, initially only a small share of users (for example 5 %) gets the new version. If all goes well, the share is increased.

In Depth

  • Rollback: back to the last working version, ideally in seconds.
  • Feature flags: New features are shipped but off. You switch them on gradually, independent of deployment (feature flags (kill switch)).
  • Database changes: must work with old and new versions (“first expand, then switch, then clean up”).
  • Vercel preview: Every pull request gets its own preview environment.

See also: CI/CD pipeline, Database migration