Google Cloud Professional Cloud Developer — Question 18
You are load testing your server application. During the first 30 seconds, you observe that a previously inactive Cloud Storage bucket is now servicing 2000 write requests per second and 7500 read requests per second. Your application is now receiving intermittent 5xx and 429 HTTP responses from the Cloud Storage
JSON API as the demand escalates. You want to decrease the failed responses from the Cloud Storage API.
What should you do?
Answer options
- A. Distribute the uploads across a large number of individual storage buckets.
- B. Use the XML API instead of the JSON API for interfacing with Cloud Storage.
- C. Pass the HTTP response codes back to clients that are invoking the uploads from your application.
- D. Limit the upload rate from your application clients so that the dormant bucket's peak request rate is reached more gradually.
Correct answer: D
Explanation
The correct answer is D because limiting the upload rate allows the Cloud Storage bucket to handle requests more effectively, reducing the likelihood of receiving 5xx and 429 errors due to sudden spikes in demand. Options A and B do not address the root cause of the issue related to request rates, and option C would not prevent the errors from occurring in the first place.