Skip to main content
PreparationZone Logo
PrepZone

Zero-Downtime Deployment

Rolling updates, blue-green, and feature flags for BookStore microservices.

Pass checkpoint below

Why this matters

  • Rolling updates and blue/green deploys keep BookStore selling during releases.
  • Database migrations must be backward compatible across old and new pods.
  • SRE interviews tie deploy strategy to error budgets and health probes.

Rolling updates

L1 · Fresher

Kubernetes replaces pods gradually while readiness probes gate traffic to healthy instances.

Blue-green

L2 · Intermediate

Switch traffic between two environments after smoke tests — fast rollback by flipping routes.

Feature flags

L3 · Advanced

Decouple deploy from release — dark launch new checkout flow to internal users first.

Database compatibility

L4 · Expert

Ship schema changes compatible with both old and new app versions during rolling deploys.

StreamHub production architecture (AWS)

HTTPSstaticmissAPICLIENT
Mobile / WebStreamHub cli…
NETWORK
Route 53GeoDNS routing
NETWORK
CloudFrontCDN + WAF edge
NETWORK
AWS ALBTLS terminati…
NETWORK
API GatewayJWT · rate li…
STORAGE
Amazon S3media origin
COMPUTE
Amazon EKSAPI · auth · …
DATABASE
ElastiCachesessions · ho…
DATABASE
RDS Postgresprimary + rep…
INTEGRATION
Amazon MSKdomain events
ANALYTICS
OpenSearchstream discov…
OPS
CloudWatchmetrics · X-R…
End-to-end path from user to data — reference this when placing any new service.

Hook

BookStore deploys ten times a day. Rolling updates must not drop connections or serve incompatible API contracts to mixed client versions during the cutover.

Backward-compatible schema

Expand-contract migrations: add nullable columns first, deploy code that writes both fields, backfill, then remove old columns in a later release. Flyway scripts align with this sequence.

The rest of this guide is part of Pro

Free covers every fresher guide in full. Pro unlocks Senior, Staff and Architect guides across every track.

Still to come · 6 sections

  • Blue-green or rolling with health
  • API compatibility
  • BookStore in action
  • Runnable BookStore lab
  • Failure modes in production
  • Session and sticky traffic

Test yourself

Answer these before moving on — recall is what makes it stick.