Pass the Google Cloud Developer Professional-Cloud-Developer Questions and answers with CertsForce

Viewing page 3 out of 3 pages
Viewing questions 21-30 out of questions
Questions # 21:

Your team is writing a backend application to implement the business logic for an interactive voice response (IVR) system that will support a payroll application. The IVR system has the following technical characteristics:

• Each customer phone call is associated with a unique IVR session.

• The IVR system creates a separate persistent gRPC connection to the backend for each session.

• If the connection is interrupted, the IVR system establishes a new connection, causing a slight latency for that call.

You need to determine which compute environment should be used to deploy the backend application. Using current call data, you determine that:

• Call duration ranges from 1 to 30 minutes.

• Calls are typically made during business hours.

• There are significant spikes of calls around certain known dates (e.g., pay days), or when large payroll changes occur.

You want to minimize cost, effort, and operational overhead. Where should you deploy the backend application?

Options:

A.

Compute Engine


B.

Google Kubernetes Engine cluster in Standard mode


C.

Cloud Functions


D.

Cloud Run


Expert Solution
Questions # 22:

Your team is responsible for maintaining an application that aggregates news articles from many different sources. Your monitoring dashboard contains publicly accessible real-time reports and runs on a Compute Engine instance as a web application. External stakeholders and analysts need to access these reports via a secure channel without authentication. How should you configure this secure channel?

Options:

A.

Add a public IP address to the instance. Use the service account key of the instance to encrypt the traffic.


B.

Use Cloud Scheduler to trigger Cloud Build every hour to create an export from the reports. Store the reports in a public Cloud Storage bucket.


C.

Add an HTTP(S) load balancer in front of the monitoring dashboard. Configure Identity-Aware Proxy to secure the communication channel.


D.

Add an HTTP(S) load balancer in front of the monitoring dashboard. Set up a Google-managed SSL certificate on the load balancer for traffic encryption.


Expert Solution
Questions # 23:

You have deployed an HTTP(s) Load Balancer with the gcloud commands shown below.

Question # 23

Health checks to port 80 on the Compute Engine virtual machine instance are failing and no traffic is sent to your instances. You want to resolve the problem.

Which commands should you run?

Options:

A.

gcloud compute instances add-access-config ${NAME}-backend-instance-1


B.

gcloud compute instances add-tags ${NAME}-backend-instance-1 --tags http-server


C.

gcloud compute firewall-rules create allow-lb --network load-balancer --allow

tcp --source-ranges 130.211.0.0/22,35.191.0.0/16 --direction INGRESS


D.

gcloud compute firewall-rules create allow-lb --network load-balancer --allow

tcp --destination-ranges 130.211.0.0/22,35.191.0.0/16 --direction EGRESS


Expert Solution
Questions # 24:

You recently developed a new service on Cloud Run. The new service authenticates using a custom service and then writes transactional information to a Cloud Spanner database. You need to verify that your application can support up to 5,000 read and 1,000 write transactions per second while identifying any bottlenecks that occur. Your test infrastructure must be able to autoscale. What should you do?

Options:

A.

Build a test harness to generate requests and deploy it to Cloud Run. Analyze the VPC Flow Logs using Cloud Logging.


B.

Create a Google Kubernetes Engine cluster running the Locust or JMeter images to dynamically generate load tests. Analyze the results using Cloud Trace.


C.

Create a Cloud Task to generate a test load. Use Cloud Scheduler to run 60,000 Cloud Task transactions per minute for 10 minutes. Analyze the results using Cloud Monitoring.


D.

Create a Compute Engine instance that uses a LAMP stack image from the Marketplace, and use Apache Bench to generate load tests against the service. Analyze the results using Cloud Trace.


Expert Solution
Questions # 25:

You are planning to deploy your application in a Google Kubernetes Engine (GKE) cluster. Your application

can scale horizontally, and each instance of your application needs to have a stable network identity and its

own persistent disk.

Which GKE object should you use?

Options:

A.

Deployment


B.

StatefulSet


C.

ReplicaSet


D.

ReplicaController


Expert Solution
Questions # 26:

You are designing a resource-sharing policy for applications used by different teams in a Google Kubernetes Engine cluster. You need to ensure that all applications can access the resources needed to run. What should you do? (Choose two.)

Options:

A.

Specify the resource limits and requests in the object specifications.


B.

Create a namespace for each team, and attach resource quotas to each namespace.


C.

Create a LimitRange to specify the default compute resource requirements for each namespace.


D.

Create a Kubernetes service account (KSA) for each application, and assign each KSA to the namespace.


E.

Use the Anthos Policy Controller to enforce label annotations on all namespaces. Use taints and tolerations to allow resource sharing for namespaces.


Expert Solution
Questions # 27:

Your team is developing a new application using a PostgreSQL database and Cloud Run. You are responsible for ensuring that all traffic is kept private on Google Cloud. You want to use managed services and follow Google-recommended best practices. What should you do?

Options:

A.

1. Enable Cloud SQL and Cloud Run in the same project.

2. Configure a private IP address for Cloud SQL. Enable private services access.

3. Create a Serverless VPC Access connector.

4. Configure Cloud Run to use the connector to connect to Cloud SQL.


B.

1. Install PostgreSQL on a Compute Engine virtual machine (VM), and enable Cloud Run in the same project.

2. Configure a private IP address for the VM. Enable private services access.

3. Create a Serverless VPC Access connector.

4. Configure Cloud Run to use the connector to connect to the VM hosting PostgreSQL.


C.

1. Use Cloud SQL and Cloud Run in different projects.

2. Configure a private IP address for Cloud SQL. Enable private services access.

3. Create a Serverless VPC Access connector.

4. Set up a VPN connection between the two projects. Configure Cloud Run to use the connector to connect to Cloud SQL.


D.

1. Install PostgreSQL on a Compute Engine VM, and enable Cloud Run in different projects.

2. Configure a private IP address for the VM. Enable private services access.

3. Create a Serverless VPC Access connector.

4. Set up a VPN connection between the two projects. Configure Cloud Run to use the connector to access the VM hosting PostgreSQL


Expert Solution
Questions # 28:

Your analytics system executes queries against a BigQuery dataset. The SQL query is executed in batch and passes the contents of a SQL file to the BigQuery CLI. Then it redirects the BigQuery CLI output to another process. However, you are getting a permission error from the BigQuery CLI when the queries are executed. You want to resolve the issue. What should you do?

Options:

A.

Grant the service account BigQuery Data Viewer and BigQuery Job User roles.


B.

Grant the service account BigQuery Data Editor and BigQuery Data Viewer roles.


C.

Create a view in BigQuery from the SQL query and SELECT* from the view in the CLI.


D.

Create a new dataset in BigQuery, and copy the source table to the new dataset Query the new dataset and table from the CLI.


Expert Solution
Questions # 29:

You are developing an application that will allow users to read and post comments on news articles. You want to configure your application to store and display user-submitted comments using Firestore. How should you design the schema to support an unknown number of comments and articles?

Options:

A.

Store each comment in a subcollection of the article.


B.

Add each comment to an array property on the article.


C.

Store each comment in a document, and add the comment’s key to an array property on the article.


D.

Store each comment in a document, and add the comment’s key to an array property on the user profile.


Expert Solution
Questions # 30:

You are working on a social media application. You plan to add a feature that allows users to upload images. These images will be 2 MB – 1 GB in size. You want to minimize their infrastructure operations overhead for this feature. What should you do?

Options:

A.

Change the application to accept images directly and store them in the database that stores other user information.


B.

Change the application to create signed URLs for Cloud Storage. Transfer these signed URLs to the client application to upload images to Cloud Storage.


C.

Set up a web server on GCP to accept user images and create a file store to keep uploaded files. Change the application to retrieve images from the file store.


D.

Create a separate bucket for each user in Cloud Storage. Assign a separate service account to allow write access on each bucket. Transfer service account credentials to the client application based on user information. The application uses this service account to upload images to Cloud Storage.


Expert Solution
Viewing page 3 out of 3 pages
Viewing questions 21-30 out of questions