Google certification · Exam Professional-Cloud-Developer

Professional-Cloud-Developer Mock Exam Page 4

Google Certified Professional - Cloud Developer

Free Professional-Cloud-Developer mock exam questions 31–40, each with the answer and an explanation.

20 questions · 33 minutes · free, no sign-up

Free Professional-Cloud-Developer questions

31–40 of 75 free
Question 31 Choose 2
You are deploying a microservices application to Google Kubernetes Engine (GKE) that will broadcast livestreams. You expect unpredictable traffic patterns and large variations in the number of concurrent users. Your application must meet the following requirements:
  • Scales automatically during popular events and maintains high availability
  • Is resilient in the event of hardware failures
How should you configure the deployment parameters? (Choose two.)
Show answerHide answer

Correct answer: A, C Distribute your workload evenly using a multi-zonal node pool.Use cluster autoscaler to resize the number of nodes in the node pool, and use a Horizontal Pod Autoscaler to scale the workload.

Question 32 Choose 1
Your application is controlled by a managed instance group. You want to share a large read-only data set between all the instances in the managed instance group. You want to ensure that each instance can start quickly and can access the data set via its filesystem with very low latency. You also want to minimize the total cost of the solution. What should you do?
Show answerHide answer

Correct answer: C Move the data to a Compute Engine persistent disk, and attach the disk in read-only mode to multiple Compute Engine virtual machine instances.

Question 33 Choose 1
Your organization has recently begun an initiative to replatform their legacy applications onto Google Kubernetes Engine. You need to decompose a monolithic application into microservices. Multiple instances have read and write access to a configuration file, which is stored on a shared file system. You want to minimize the effort required to manage this transition, and you want to avoid rewriting the application code. What should you do?
Show answerHide answer

Correct answer: D Create a new ConfigMap and volumeMount to store the contents of the configuration file.

Explanation

ConfigMaps bind non-sensitive configuration artifacts such as configuration files, command-line arguments, and environment variables to your Pod containers and system components at runtime.
A ConfigMap separates your configurations from your Pod and components, which helps keep your workloads portable. This makes their configurations easier to change and manage, and prevents hardcoding configuration data to Pod specifications.
Question 34 Choose 1
Show answerHide answer

Correct answer: C Option C

Question 35 Choose 1
You are running a web application on Google Kubernetes Engine that you inherited. You want to determine whether the application is using libraries with known vulnerabilities or is vulnerable to XSS attacks. Which service should you use?
Show answerHide answer

Correct answer: C Web Security Scanner

Explanation

Web Security Scanner identifies security vulnerabilities in your App Engine, Google Kubernetes Engine (GKE), and Compute Engine web applications. It crawls your application, following all links within the scope of your starting URLs, and attempts to exercise as many user inputs and event handlers as possible.
Question 36 Choose 1
The new version of your containerized application has been tested and is ready to deploy to production on Google Kubernetes Engine. You were not able to fully load-test the new version in pre-production environments, and you need to make sure that it does not have performance problems once deployed. Your deployment must be automated. What should you do?
Show answerHide answer

Correct answer: C Deploy the application via a continuous delivery pipeline using blue/green deployments. Use Cloud Monitoring to look for performance issues, and launch fully when the metrics support it.

Question 37 Choose 1
You are deploying a Python application to Cloud Run using Cloud Build. The Cloud Build pipeline is shown below:

You want to optimize deployment times and avoid unnecessary steps What should you do?
Show answerHide answer

Correct answer: B Add the —cache-from argument to the Docker build step in your build config file.

Question 38 Choose 1
You are a developer at a large corporation You manage three Google Kubernetes Engine clusters. Your team’s developers need to switch from one cluster to another regularly without losing access to their preferred development tools. You want to configure access to these clusters using the fewest number of steps while following Google-recommended best practices. What should you do?
Show answerHide answer

Correct answer: D In a configuration file, define the clusters users, and contexts Email the file to the developers and ask them to use kubect1 config to add cluster, user and context details.

Question 39 Choose 1
You have written a Cloud Function that accesses other Google Cloud resources. You want to secure the environment using the principle of least privilege. What should you do?
Show answerHide answer

Correct answer: D Create a new service account that has a custom IAM role to access the resources. The deployer is given permission to act as the new service account.

Question 40 Choose 1
Your teammate has asked you to review the code below, which is adding a credit to an account balance in Cloud Datastore. Which improvement should you suggest your teammate make?
Show answerHide answer

Correct answer: A Get the entity with an ancestor query.

Full mock exam

Sit the Professional-Cloud-Developer exam before exam day

Full-length mocks with the same number of questions and the same time limit as the real Professional-Cloud-Developer exam. Every attempt draws a new set of questions from the full bank, so you can keep going until you pass comfortably.

Get full Professional-Cloud-Developer mock exam
  • 65questions per mock
  • 105 mintime limit
  • 253questions in the bank
  • Newmock on every attempt