Google Professional Cloud DevOps Engineer Question 156
Select 3Google Cloud PlatformYour team recently implemented a CI/CD pipeline using Cloud Build to deploy a containerized application to Google Kubernetes Engine (GKE). However, the deployment process is failing intermittently, and the error logs indicate issues with exceeding API rate limits. What actions should you take to address this problem?
- A
Use Cloud Build's concurrency control to limit the number of builds running simultaneously.
- B
Enable retries in the Cloud Build pipeline for steps that interact with the GKE API.
- C
Migrate the pipeline to a different CI/CD tool to avoid rate limits on GKE.
- D
Reduce the deployment frequency to avoid hitting the API rate limits.
- E
Implement caching mechanisms to minimize redundant API calls during the pipeline execution.
Show answer and explanation
Correct answers: A, B, E
Explanation
The problem arises from exceeding the GKE API rate limits. To address this, you can reduce the number of concurrent API calls (using Cloud Build's concurrency control), handle transient errors with retries, and optimize the pipeline by implementing caching mechanisms to avoid unnecessary API requests. These actions help mitigate the issue without compromising deployment frequency or changing CI/CD tools unnecessarily.
- A. Correct.
Using Cloud Build's concurrency control helps reduce the number of concurrent builds, which can decrease the overall number of API calls and prevent hitting rate limits.
- B. Correct.
Enabling retries allows the pipeline to handle transient errors caused by API rate limits, ensuring the deployment can eventually succeed.
- C. Incorrect.
Migrating to a different CI/CD tool does not address the root cause, as the API rate limits are set by GKE and would still apply regardless of the tool used.
- D. Incorrect.
Reducing deployment frequency is not an ideal solution in a DevOps environment, as it sacrifices deployment agility and does not address the underlying issue.
- E. Correct.
Implementing caching mechanisms minimizes redundant API calls, potentially reducing the load on the GKE API and preventing rate limit issues.