Google Cloud Professional Cloud Developer — Question 158
Your company has deployed a new API to a Compute Engine instance. During testing, the API is not behaving as expected. You want to monitor the application over 12 hours to diagnose the problem within the application code without redeploying the application. Which tool should you use?
Answer options
- A. Cloud Trace
- B. Cloud Monitoring
- C. Cloud Debugger logpoints
- D. Cloud Debugger snapshots
Correct answer: C
Explanation
Cloud Debugger logpoints allow you to insert logging statements into your application code without needing to redeploy it, making it ideal for diagnosing issues during runtime. Other options, such as Cloud Trace and Cloud Monitoring, focus on performance and metrics rather than direct inspection of code execution. Cloud Debugger snapshots provide a view of the application's state but are not as effective for real-time code diagnostics as logpoints.