Google Cloud Associate Cloud Engineer — Question 25
Your organization is a financial company that needs to store audit log files for 3 years. Your organization has hundreds of Google Cloud projects. You need to implement a cost-effective approach for log file retention. What should you do?
Answer options
- A. Create an export to the sink that saves logs from Cloud Audit to BigQuery.
- B. Create an export to the sink that saves logs from Cloud Audit to a Coldline Storage bucket.
- C. Write a custom script that uses logging API to copy the logs from Stackdriver logs to BigQuery.
- D. Export these logs to Cloud Pub/Sub and write a Cloud Dataflow pipeline to store logs to Cloud SQL.
Correct answer: B
Explanation
The correct answer is B because Coldline Storage is specifically designed for long-term storage of infrequently accessed data, making it cost-effective for retaining audit logs for three years. Options A and C involve BigQuery, which is more suitable for frequent queries rather than long-term storage, and D adds unnecessary complexity with Cloud Pub/Sub and Cloud Dataflow for this scenario.