- rtshkmr's digital garden/
- References/
- Architecture Design Basics/
- Pattern Taxonomy/
- Deployment & Evolution/
- Deployment Strategies/
Deployment Strategies
··
160 words·
1 min
Table of Contents
🟡 P2 — mentioned in designs but rarely the crux; know the trade-offs
Strategies #
| Strategy | Mechanism | Rollback | Risk |
|---|---|---|---|
| Rolling | Replace instances one-by-one | Stop and reverse | Low |
| Blue-Green | Two identical environments, swap traffic | Swap back | Medium |
| Canary | Route small % to new version, observe | Route back | Lowest |
| Shadow/Dark | Mirror traffic to new version, discard results | N/A (no impact) | Lowest |
Instinct #
Canary for most production services. Route 1-5% of traffic to the new version, monitor RED metrics for 15-30 minutes, then gradually increase. Blue-Green for database migrations where you need instant rollback capability. Rolling for stateless services where canary infrastructure isn’t available.
Dark Launches (Shadow Traffic) #
Mirror production traffic to the new version but discard the results.
Production traffic
├──→ Live system (serves response to user)
└──→ Shadow system (processes same request, response discarded)
↓
Compare: latency, errors, output differencesUse cases: Validate migration handles real queries; load-test with production patterns; verify rewrite produces identical results.
Instinct: Dark launches are the safest validation because there’s zero user impact. Pair with Feature Flags for controlled rollout after validation.
References #
- Dark Launching — Martin Fowler