A platform team wants two automatic scaling behaviours: when CPU usage across a Deployment's Pods rises, more replicas of that Deployment should be created; and when Pods cannot be scheduled because every node is full, more worker nodes should be added to the cluster. Which pairing correctly maps each behaviour to the component responsible for it?
- AThe cluster autoscaler adds replicas based on observed metrics, and the HorizontalPodAutoscaler adds nodes when Pods are unschedulable.
- BThe VerticalPodAutoscaler adds replicas based on observed metrics, and the cluster autoscaler resizes existing Pods to fit the node.
- CThe HorizontalPodAutoscaler adds both replicas and nodes, so no separate node-scaling component is required.
- DThe HorizontalPodAutoscaler adds replicas based on observed metrics, and the cluster autoscaler adds nodes when Pods are unschedulable. Correct
Why A is wrong: Tempting because both names contain 'autoscaler', but the roles are reversed: the HPA scales Pods, not nodes, and the cluster autoscaler scales nodes, not replicas.
Why B is wrong: Tempting because the VPA is a real scaling component, but it adjusts a Pod's own requests and limits rather than adding replicas, and the cluster autoscaler adds nodes rather than resizing Pods.
Why C is wrong: Tempting because the HPA is the best-known autoscaler, but it only changes replica counts; it has no ability to provision worker nodes, which is the cluster autoscaler's job.
Why D is correct: Correct: the HPA controller adjusts a workload's replica count from metrics such as CPU, while the cluster autoscaler watches for pending Pods that cannot be scheduled and grows the node pool to fit them.