Google Cloud Professional Cloud Architect — Question 252
Your company has a Google Cloud project that uses BigQuery for data warehousing on a pay-per-use basis. You want to monitor queries in real time to discover the most costly queries and which users spend the most. What should you do?
Answer options
- A. 1. In the BigQuery dataset that contains all the tables to be queried, add a label for each user that can launch a query. 2. Open the Billing page of the project. 3. Select Reports. 4. Select BigQuery as the product and filter by the user you want to check.
- B. 1. Create a Cloud Logging sink to export BigQuery data access logs to BigQuery. 2. Perform a BigQuery query on the generated table to extract the information you need.
- C. 1. Create a Cloud Logging sink to export BigQuery data access logs to Cloud Storage. 2. Develop a Dataflow pipeline to compute the cost of queries split by users.
- D. 1. Activate billing export into BigQuery. 2. Perform a BigQuery query on the billing table to extract the information you need.
Correct answer: B
Explanation
The correct answer is B because exporting BigQuery data access logs to BigQuery allows for detailed analysis of query costs and user spending. Option A focuses on labeling users but does not directly address monitoring costs, while Option C involves additional steps that complicate the process without immediate benefits. Option D, while useful for billing insights, does not provide real-time monitoring of query performance.