Google Cloud Professional Cloud Developer — Question 153
Your company’s product team has a new requirement based on customer demand to autoscale your stateless and distributed service running in a Google Kubernetes Engine (GKE) duster. You want to find a solution that minimizes changes because this feature will go live in two weeks. What should you do?
Answer options
- A. Deploy a Vertical Pod Autoscaler, and scale based on the CPU load.
- B. Deploy a Vertical Pod Autoscaler, and scale based on a custom metric.
- C. Deploy a Horizontal Pod Autoscaler, and scale based on the CPU toad.
- D. Deploy a Horizontal Pod Autoscaler, and scale based on a custom metric.
Correct answer: C
Explanation
The correct answer is C, as a Horizontal Pod Autoscaler is designed to automatically adjust the number of pods in a deployment based on observed CPU utilization, making it suitable for a stateless service. Options A and B are incorrect because a Vertical Pod Autoscaler is not ideal for this scenario since it adjusts resources for individual pods rather than the number of pods. Option D is also incorrect as it introduces a custom metric, which may require more setup and changes than necessary given the tight timeline.