Professional Cloud DevOps Engineer Practice Test

Professional Cloud DevOps Engineer Practice Test practice questions, page 7 of 10, with answer review and explanations.

Question 31

Your team is designing a new application for deployment into Google Kubernetes Engine (GKE). You need to set up monitoring to collect and aggregate various application-level metrics in a centralized location. You want to use Google Cloud Platform services while minimizing the amount of work required to set up monitoring. What should you do?

  1. Publish various metrics from the application directly to the Stackdriver Monitoring API, and then observe these custom metrics in Stackdriver.
  2. Install the Cloud Pub/Sub client libraries, push various metrics from the application to various topics, and then observe the aggregated metrics in Stackdriver.
  3. Install the OpenTelemetry client libraries in the application, configure Stackdriver as the export destination for the metrics, and then observe the application's metrics in Stackdriver.
  4. Emit all metrics in the form of application-specific log messages, pass these messages from the containers to the Stackdriver logging collector, and then observe metrics in Stackdriver.

Question 32

You support a production service that runs on a single Compute Engine instance. You regularly need to spend time on recreating the service by deleting the crashing instance and creating a new instance based on the relevant image. You want to reduce the time spent performing manual operations while following Site Reliability Engineering principles. What should you do?

  1. File a bug with the development team so they can find the root cause of the crashing instance.
  2. Create a Managed instance Group with a single instance and use health checks to determine the system status.
  3. Add a Load Balancer in front of the Compute Engine instance and use health checks to determine the system status.
  4. Create a Stackdriver Monitoring dashboard with SMS alerts to be able to start recreating the crashed instance promptly after it was crashed.

Question 33

Your application artifacts are being built and deployed via a CI/CD pipeline. You want the CI/CD pipeline to securely access application secrets. You also want to more easily rotate secrets in case of a security breach. What should you do?

  1. Prompt developers for secrets at build time. Instruct developers to not store secrets at rest.
  2. Store secrets in a separate configuration file on Git. Provide select developers with access to the configuration file.
  3. Store secrets in Cloud Storage encrypted with a key from Cloud KMS. Provide the CI/CD pipeline with access to Cloud KMS via IAM.
  4. Encrypt the secrets and store them in the source code repository. Store a decryption key in a separate repository and grant your pipeline access to it.

Question 34

Your company follows Site Reliability Engineering practices. You are the person in charge of Communications for a large, ongoing incident affecting your customer-facing applications. There is still no estimated time for a resolution of the outage. You are receiving emails from internal stakeholders who want updates on the outage, as well as emails from customers who want to know what is happening. You want to efficiently provide updates to everyone affected by the outage. What should you do?

  1. Focus on responding to internal stakeholders at least every 30 minutes. Commit to ג€next updateג€ times.
  2. Provide periodic updates to all stakeholders in a timely manner. Commit to a ג€next updateג€ time in all communications.
  3. Delegate the responding to internal stakeholder emails to another member of the Incident Response Team. Focus on providing responses directly to customers.
  4. Provide all internal stakeholder emails to the Incident Commander, and allow them to manage internal communications. Focus on providing responses directly to customers.

Question 35

Your team uses Cloud Build for all CI/CD pipelines. You want to use the kubectl builder for Cloud Build to deploy new images to Google Kubernetes Engine (GKE). You need to authenticate to GKE while minimizing development effort. What should you do?

  1. Assign the Container Developer role to the Cloud Build service account.
  2. Specify the Container Developer role for Cloud Build in the cloudbuild.yaml file.
  3. Create a new service account with the Container Developer role and use it to run Cloud Build.
  4. Create a separate step in Cloud Build to retrieve service account credentials and pass these to kubectl.