exam questions

Exam Professional Cloud Developer All Questions

View all questions & answers for the Professional Cloud Developer exam

Exam Professional Cloud Developer topic 1 question 313 discussion

Actual exam question from Google's Professional Cloud Developer
Question #: 313
Topic #: 1
[All Professional Cloud Developer Questions]

Your infrastructure team is responsible for creating and managing Compute Engine VMs. Your team uses the Google Cloud console and gcloud CLI to provision resources for the development environment. You need to ensure that all Compute Engine VMs are labeled correctly for compliance reasons. In case of missing labels, you need to implement corrective actions so the labels are configured accordingly without changing the current deployment process. You want to use the most scalable approach. What should you do?

  • A. Use a Cloud Audit Logs trigger to invoke a Cloud Function when a Compute Engine VM is created. Check for missing labels and assign them if necessary.
  • B. Deploy resources with Terraform. Use the gcloud terraform vet command with a policy to ensure that every Compute Engine VM that is provisioned by Terraform has labels set.
  • C. Write a script to check all Compute Engine VMs for missing labels regularly by using Cloud Scheduler. Use the script to assign the labels.
  • D. Check all Compute Engine VMs for missing labels regularly. Use the console to assign the labels.
Show Suggested Answer Hide Answer
Suggested Answer: A 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
yokoyan
2 weeks, 6 days ago
Selected Answer: A
Gemini’s Explanation A:〇 It offers real-time enforcement via Cloud Functions triggered by Cloud Audit Logs, ensuring labels are applied immediately regardless of the provisioning method and scaling automatically. This approach doesn't require changes to the existing deployment process. B:× This requires adopting Terraform, which contradicts the requirement of not changing the current deployment process. It also doesn't cover VMs provisioned outside of Terraform. C:× Scheduled checks are not real-time, leading to potential delays in compliance. The scalability of a custom script might also become a concern in large environments. D:× Manual checks and console-based labeling are not scalable or efficient for managing a large number of VMs and require constant manual effort.
upvoted 1 times
...
anshad666
6 months, 3 weeks ago
Selected Answer: A
Use a Cloud Audit Logs trigger to invoke a Cloud Function when a Compute Engine VM is created. Check for missing labels and assign them if necessary.
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago