Free — no signup required

Introduction: The Staging Bottleneck

2 min read

The "Queue for QA" Problem

Imagine a single bathroom in a shared office. Everyone needs it, but only one person can use it at a time. If someone is in there for an hour, everyone else waits. This is exactly what happens with a single shared staging environment.

In traditional workflows, teams maintain one long-lived environment called "Staging" or "QA." It is a shared resource, and sharing creates contention:

  • Developer Alice merges a feature. It deploys to Staging.
  • Developer Bob wants to test his feature. He has to wait for Alice to finish — or he deploys over her, breaking her tests entirely.
  • Meanwhile, a QA engineer is trying to validate a hotfix on the same environment.

This creates a bottleneck. High-velocity teams cannot function if they must queue to test their code in a realistic environment. The problem compounds as teams grow: more developers means more PRs, more conflicts, and more time wasted waiting.

The Solution: Environments on Demand

Instead of one long-lived Staging environment, we create a temporary, isolated environment for every single Pull Request. Each environment is a complete, functional copy of the application stack, accessible at a unique URL:

  • PR #101 gets pr-101.dev.mycompany.com
  • PR #102 gets pr-102.dev.mycompany.com

Reviewers can test features independently and in parallel. When the PR is merged or closed, the environment is destroyed automatically. No cleanup tickets, no "who left this running?" Slack messages.

This pattern is called Ephemeral Environments (also called Preview Environments or Dynamic Environments). The word "ephemeral" means short-lived by design — these environments exist only as long as the PR does.

Key Point: The shift from shared staging to ephemeral environments is not just a tooling change — it is a cultural one. It moves the responsibility for environment management from a central ops team to the CI/CD pipeline itself. The pipeline becomes the environment manager, and developers get self-service access to realistic test environments without coordination overhead.

This is one of 18 chapters

Every chapter is free — Kubernetes, Terraform, SRE, distributed systems, and more — with fast daily review built in.

Sign up free