REST API, mission 6 of 7
Launch-day traffic
advanced, about 12 minutes, in the Kubernetes Simulator
Opens once you pass Out of memory.
The briefing
Marketing is about to email every customer. Traffic will jump tenfold, and nobody knows exactly when.
A HorizontalPodAutoscaler watches the pods' CPU against what each one *requested* and changes the Deployment's replica count to hold a target — here, 50% of request. Measured against nothing, it can't do anything at all.
What you'll do
- Autoscale orders between 2 and 8 pods at 50% CPU
- The autoscaler can read the pods' CPU
- Scale out for the launch: at least 6 ready pods
- Bonus star: Watch it decide: kubectl get hpa or describe hpa after the spike
The mission checks the cluster, not your keystrokes: any fix that works, passes.
Read first
More REST API missions
- 1. Config, not code
- 2. Read at start
- 3. CrashLoopBackOff
- 4. Ready when it's ready
- 5. Out of memory
- 6. Launch-day traffic
- 7. Rotate the password