GCP ACE · Question 37 · Domain 4.4: Managing storage and database solutions
Your application generates daily log files that are stored in a Cloud Storage Standard bucket. These logs are frequently accessed for the first 30 days. After 30 days, they are rarely accessed but must be kept for 1 year for compliance, after which they can be deleted.
What is the MOST automated and cost-effective way to manage these files?
Answer options:
Write a Cloud Function that runs daily, checks the age of each file, and uses the gsutil command to move older files to a Coldline bucket.
Configure an Object Lifecycle Management policy on the bucket to transition objects to Coldline storage after 30 days, and delete them after 365 days.
Manually change the storage class of the bucket to Coldline at the end of every month.
Use Cloud Scheduler to trigger a Dataflow job monthly to compress and move the logs to Archive storage.
50 questions · hints · full answers · grading