Professional Cloud Architect · Free Practice Question Medium
Question 40
As a cloud architect, you are working with an e-commerce client who expects a significant increase in traffic to their application hosted on Google Kubernetes Engine (GKE) during an upcoming sales event. To manage the increased load, the client wishes to enable autoscaling for their application. However, they want to ensure that any newly created pods during autoscaling are fully ready to handle traffic before being included in the service. Which of the following solutions should you implement?
-
A
Configure a startup script in the pod specification to delay service registration.
-
B
Configure a readiness probe in your pod specification.
-
C
Configure a liveness probe in your pod specification.
-
D
Enable Cluster Autoscaler on your GKE cluster.
Reveal correct answer
Correct answer: B
A.
It would not be an effective solution, as it would delay all pods, not just the ones that are not ready. It would also require manual intervention to manage the delay.
B.
A readiness probe is used in Kubernetes to determine when a pod is ready to accept traffic. The load balancer only sends traffic to pods that pass their readiness probe, ensuring that new pods are fully ready before they start receiving traffic.
C.
Configuring a liveness probe in your pod specification would be used to know when to restart a pod, but it does not determine when a pod is ready to accept traffic.
D.
Enabling Cluster Autoscaler on your GKE cluster would indeed help manage the number of nodes based on the traffic, but it would not ensure that new pods are ready before they receive traffic.
Discussion
Think the marked answer is wrong, or have a better explanation? Share it below — comments appear after review.
