
Answer-first summary for fast verification
Answer: Enable the Cloud Profiler API and add google-cloud-profiler to your requirements.txt file, Import google cloud profiler module and call the google cloud profiler. start function
The correct approach involves enabling the Cloud Profiler API and including `google-cloud-profiler` in your `requirements.txt` file for download. Additionally, the Cloud Profiler module must be imported and started within your application. This method is specifically designed for continuous monitoring of CPU and memory usage. Other options like Cloud Trace are not suitable for this purpose, and manual installation of packages is not feasible in the App Engine Standard Environment due to restricted access to the underlying instance. For more details, refer to the Cloud Profiler overview and guidelines for profiling Python applications.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
No comments yet.
Your company is deploying a Python application on Google App Engine Standard Environment and needs to continuously monitor CPU usage in production. Which steps should you take to accomplish this?
A
Install pip and Install the Trace package
B
Enable the Cloud Profiler API and add google-cloud-profiler to your requirements.txt file
C
Install pip and Install the Cloud Profiler package
D
Enable the Cloud Trace API
E
Import google cloud profiler module and call the google cloud profiler. start function