Question-49: During the process of analyzing the numerous website logs of your client in search of vulnerabilities, you run into the issue of having to generate a large number of log files as part of the data processing. You are working on a solution to delete backup log files from your backup Cloud Storage bucket that are older than ninety days. You want to get the most out of your continuous investment in cloud storage. What is it that you ought to do?
A. Write a lifecycle management rule in XML and push it to the bucket with gsutil
B. Write a lifecycle management rule in JSON and push it to the bucket with gsutil
C. Create a cron script using the command gsutil ls �gs:/backups/� to search for and delete things that are more than ninety days old.
D. Schedule a cron script using gsutil ls “gs://backups/� to find and remove items older than 90 days and schedule it with cron
Correct Answer
Get All 340 Questions and Answer for Google Professional Cloud Architect
: 2 Explanation: Since Google Cloud Schedule already has cron job scheduling functionality built in, Option 4 would be ranked lower on Google's priority list than Option 3. Because Google also offers its own lifecycle management command line prompt known as gcloud lifecycle, either Option 1 or Option 2 may be used. JSON is somewhat more efficient than XML due to the distinguisher, which makes use of a Trie tree for the processing of alphanumeric data. Therefore, if you have to select between options 1 and 2, go with option 2. When viewed from the point of view of the GCP operator, Option 2 is somewhat more efficient. When it comes to lifecycle management, the gsutil command only accepts json as an input. When it comes to API, you have the option of using either XML or json. The format of Policy is JSON. It makes no difference whether you use AWS or GCP. Option 1 is not a feasible choice due to the fact that life cycle policies are not expressed in XML. Option 2 is a sensible choice and is natural to the cloud. Option 3 necessitates the use of a cron script, which in turn necessitates the use of anything to execute the script. This method is not cloud native. A non-cloud native solution, method D calls for the creation of a cron script, which in turn requires something to execute the script.