Google Professional Cloud Developer Question 165
Single answerGoogle Cloud PlatformYou are developing a cloud-native application that processes sensitive user data and are required to comply with a regulation mandating that all user data must be retained for exactly 7 years and then automatically deleted. Which approach should you use to meet these data retention requirements?
- A
Use Cloud Storage with a bucket-level retention policy set to 7 years and enable Object Lifecycle Management to automatically delete objects after the retention period.
- B
Store the data in Cloud SQL and implement a manual process to delete records older than 7 years.
- C
Use Firestore and write a scheduled Cloud Function to query and delete documents older than 7 years.
- D
Store data in BigQuery and use a table expiration time of 7 years to manage automatic deletion of records.
Show answer and explanation
Correct answer: A
Explanation
To meet strict data retention requirements, it is critical to use a solution that enforces retention policies natively and automatically deletes data after the specified period. Cloud Storage's bucket-level retention policies and Object Lifecycle Management provide a robust, automated, and compliant approach for managing data retention and deletion timelines.
- A. Correct.
This is the correct option. Cloud Storage provides bucket-level retention policies that enforce data retention for a specified period, and Object Lifecycle Management can automatically delete objects after the retention period.
- B. Incorrect.
This is incorrect because relying on a manual process to delete records increases the risk of human error and does not guarantee compliance with the retention policy.
- C. Incorrect.
This is incorrect because while Firestore allows for scheduled deletions using Cloud Functions, it requires additional setup and does not enforce data retention policies at the storage level.
- D. Incorrect.
This is incorrect because BigQuery table expiration times work at the table level, not at the individual record level, making it challenging to ensure compliance with a 7-year retention requirement for every record.