Google Professional Cloud Developer Practice Test Questions and Exam Dumps Part4 Q61-80

View Full Google Professional Cloud Developer Exam Dumps and Practice Test Dumps.

 

Question 61

A web application running on Cloud Run needs to process background tasks asynchronously while controlling retry behavior and the rate at which tasks are sent to a worker. Which Google Cloud service is most appropriate?

  1. Cloud Scheduler
  2. Cloud Tasks
  3. Cloud Trace
  4. Cloud CDN

Correct Answer: 2

Explanation

Cloud Tasks is designed for managing asynchronous work that can be executed by HTTP-based workers. It allows developers to place tasks into queues and control dispatch rates, concurrency, retries, and backoff behavior. A Cloud Run service can act as the task handler and process work independently from the original request. Cloud Scheduler is primarily intended for scheduled execution, while Cloud Trace analyzes request latency. Cloud CDN improves content delivery rather than task processing. Cloud Tasks therefore provides the application-level queueing and delivery controls required for reliable background task execution.

Question 62

A developer must coordinate several Google Cloud API calls in a defined sequence, where the output from one operation becomes an input to another. The workflow should handle conditional branches without requiring a custom orchestration service. Which service should be used?

  1. Cloud Workflows
  2. Cloud Storage
  3. Cloud Monitoring
  4. Artifact Registry

Correct Answer: 1

Explanation

Cloud Workflows provides managed orchestration for coordinating multiple services and HTTP APIs. A workflow can execute steps sequentially, pass data between steps, evaluate conditions, and handle errors without requiring developers to maintain a separate orchestration server. This makes it useful for business processes that involve several independent Google Cloud operations. Cloud Storage is intended for object storage, Cloud Monitoring focuses on observability, and Artifact Registry stores software artifacts. Using Workflows reduces custom orchestration code while providing a structured way to coordinate distributed application operations.

Question 63

An application deployed on Cloud Run must receive events from multiple Google Cloud sources. The development team wants centralized event routing based on event attributes rather than creating a separate integration mechanism for every source. What should they use?

  1. Cloud SQL
  2. Cloud Build
  3. Eventarc
  4. Cloud Profiler

Correct Answer: 3

Explanation

Eventarc provides event-driven routing between supported Google Cloud event sources and destinations such as Cloud Run. Developers can define triggers that filter events according to attributes and then route matching events to the desired target. This approach reduces the need to build custom polling or integration logic for every event source. Cloud SQL provides relational database services, Cloud Build automates build processes, and Cloud Profiler analyzes application performance. Eventarc is therefore appropriate when an application needs centralized, attribute-based event routing across supported Google Cloud services.

Question 64

A team is exposing a REST API to external consumers and wants managed API routing, authentication integration, quotas, and monitoring without implementing these capabilities directly inside every backend service. Which Google Cloud product is designed for this purpose?

  1. Cloud Storage
  2. API Gateway
  3. Cloud Bigtable
  4. Cloud Scheduler

Correct Answer: 2

Explanation

API Gateway provides a managed entry point for APIs and can integrate with backend services while applying API configuration and access controls. It can help developers manage authentication, routing, quotas, and operational visibility without duplicating those concerns across individual application services. Cloud Storage and Cloud Bigtable are data services, while Cloud Scheduler is designed for scheduled jobs. For an application that needs a managed API facade in front of backend services, API Gateway provides an appropriate developer-focused architecture and reduces the amount of API management infrastructure the team must maintain.

Question 65

A mobile application stores user profiles as documents and frequently retrieves individual records using document identifiers. The data model does not require relational joins. Which database is most suitable for this access pattern?

  1. Cloud SQL
  2. Cloud Spanner
  3. Cloud Bigtable
  4. Firestore

Correct Answer: 4

Explanation

Firestore is a document-oriented database designed for applications that store and retrieve structured data as documents within collections. It works well for user profiles and similar application data where individual documents can be accessed using identifiers and the application does not depend heavily on relational joins. Cloud SQL provides relational database engines, Cloud Spanner supports globally scalable relational workloads, and Bigtable is optimized for very large key-value and wide-column workloads. For document-centric application data with direct document access patterns, Firestore matches the stated requirements closely.

Question 66

A developer needs to let a browser upload a large object directly to Cloud Storage without exposing long-lived credentials to the browser. What mechanism should the application use?

  1. Signed URL
  2. Static external IP
  3. Cloud NAT
  4. Service account key file

Correct Answer: 1

Explanation

A signed URL provides temporary, controlled access to a specific Cloud Storage resource. An application running on a trusted backend can generate the signed URL and give it to the browser, allowing the browser to upload or download an object without receiving permanent credentials. The URL can include an expiration time and permissions appropriate to the operation. A service account key file would expose a long-lived credential and create unnecessary security risk. Static IP addresses and Cloud NAT do not provide object-level authorization for browser uploads.

Question 67

A BigQuery-based application constructs SQL statements using values supplied by users. The developer wants to reduce the risk of SQL injection while keeping query logic separate from user-provided values. What should be implemented?

  1. Hard-code every user value
  2. Disable query logging
  3. Parameterized queries
  4. Store values in Cloud Storage

Correct Answer: 3

Explanation

Parameterized queries separate SQL structure from the values supplied at runtime. In BigQuery, query parameters allow developers to provide user-controlled values without directly concatenating those values into SQL statements. This helps prevent malicious input from changing the intended query structure and also improves clarity in application code. Hard-coding values is impractical for dynamic applications, disabling logs does not address injection, and storing values in Cloud Storage does not make SQL construction safe. Parameterization is therefore the appropriate application-development practice for handling user-supplied query values.

Question 68

A Cloud Run service makes many short-lived connections to Cloud SQL and occasionally reaches the database connection limit during traffic spikes. Which application change can directly reduce unnecessary connection creation?

  1. Increase log retention
  2. Use connection pooling
  3. Add more DNS records
  4. Disable application authentication

Correct Answer: 2

Explanation

Connection pooling allows an application to reuse established database connections instead of creating a new connection for every database operation or request. This can significantly reduce connection overhead and help prevent Cloud SQL connection limits from being reached during periods of increased Cloud Run traffic. The pool should still be configured with appropriate limits because excessive pooled connections can consume database resources. Log retention, DNS records, and authentication settings do not directly solve excessive database connection creation. Proper connection pooling is therefore an effective application-level technique for managing database connectivity.

Question 69

A Bigtable application experiences uneven performance because many requests target rows whose keys share the same beginning. What database design change can help reduce hotspotting?

  1. Increase application logging
  2. Add more HTTP headers
  3. Randomize or distribute row-key prefixes
  4. Reduce authentication token lifetime

Correct Answer: 3

Explanation

Bigtable performance depends heavily on row-key design because related rows can become concentrated in the same tablet when keys follow poorly distributed patterns. If a workload repeatedly targets rows with similar prefixes, traffic can become uneven and create hotspots. Designing row keys so that frequently accessed records are distributed more effectively can improve load distribution. Depending on the workload, developers may use hashed, salted, or otherwise distributed prefixes. Logging, HTTP headers, and authentication token settings do not address Bigtable’s underlying row-key distribution or tablet-level workload concentration.

Question 70

A Pub/Sub subscriber processes messages that must be delivered in a defined order for each customer, but messages belonging to different customers can be processed independently. Which feature should the developer use?

  1. Ordering keys
  2. Signed URLs
  3. Revision tags
  4. Lifecycle rules

Correct Answer: 1

Explanation

Pub/Sub ordering keys allow messages with the same ordering-key value to be delivered to a subscriber in order, subject to the service’s ordering requirements. An application can assign each customer’s messages a customer-specific ordering key while allowing messages for different customers to proceed independently. This provides more precise ordering than forcing the entire subscription workload into a single sequential stream. Signed URLs control temporary storage access, revision tags are associated with deployed application versions, and lifecycle rules manage stored objects. Ordering keys directly address per-customer message ordering.

Question 71

A developer wants failed Pub/Sub messages to be redirected after repeated delivery attempts so that the primary subscriber does not repeatedly process permanently problematic messages. Which capability should be configured?

  1. Cloud CDN caching
  2. Dead-letter topic
  3. Cloud Profiler
  4. Artifact Registry repository

Correct Answer: 2

Explanation

A Pub/Sub dead-letter topic provides a mechanism for handling messages that cannot be successfully processed after repeated delivery attempts. Messages can be forwarded to the configured dead-letter topic according to the subscription’s delivery policy, allowing developers to isolate problematic messages for later investigation or processing. This helps prevent repeatedly failing messages from consuming the normal processing path indefinitely. Cloud CDN handles content caching, Cloud Profiler provides performance profiling, and Artifact Registry stores software artifacts. A dead-letter topic is therefore the relevant Pub/Sub capability for persistent processing failures.

Question 72

A Cloud Run application has a CPU-intensive request that occasionally requires more time than the configured request limit. Which setting should the developer review first when requests are being terminated before completion?

  1. Cloud Storage retention
  2. Request timeout
  3. DNS TTL
  4. Secret version alias

Correct Answer: 2

Explanation

Cloud Run services have a configurable request timeout that determines how long an individual request may execute before the platform terminates it. If a CPU-intensive operation legitimately requires additional processing time, the developer should first verify whether the configured timeout is sufficient for the workload. Increasing the timeout should be done carefully because long-running synchronous requests can affect resource utilization and user experience. Storage retention, DNS TTL, and Secret Manager version settings do not control the maximum duration of a Cloud Run request. The request timeout directly governs this behavior.

Question 73

A Kubernetes application frequently restarts because a container exceeds its available memory. The development team wants Kubernetes to prevent a single container from consuming excessive memory and affecting other workloads. Which configuration should they use?

  1. Resource limits
  2. ConfigMaps
  3. Ingress rules
  4. Service annotations

Correct Answer: 1

Explanation

Kubernetes resource limits define the maximum amount of a resource that a container is allowed to consume. Setting an appropriate memory limit helps prevent a container from consuming unbounded memory and interfering with other workloads on the node. Developers should normally configure resource requests as well so that Kubernetes can make appropriate scheduling decisions. ConfigMaps store non-sensitive configuration, Ingress controls network routing, and service annotations provide metadata or integration-specific configuration. Resource limits are therefore the relevant control for constraining container memory consumption within a Kubernetes workload.

Question 74

A production service needs to expose an authenticated API to clients using tokens that contain claims about the caller. The backend must verify the token’s authenticity and claims before accepting the request. Which approach is appropriate?

  1. Trust any value in an HTTP header
  2. Accept an unsigned token
  3. Validate a signed JWT
  4. Store the token in Cloud Storage

Correct Answer: 3

Explanation

A signed JSON Web Token can carry claims about a caller while allowing the receiving service to verify that the token was issued by a trusted authority and has not been modified. The backend should validate the token signature and relevant claims such as issuer, audience, expiration, and other application-specific requirements. Simply trusting an HTTP header or accepting an unsigned token does not provide reliable authentication. Storing a token in Cloud Storage also does not validate a caller’s identity. Proper JWT validation therefore provides the required authentication mechanism for the described API.

Question 75

A development team wants a Cloud Build job to run automatically whenever changes are pushed to a particular branch of its source repository. Which Cloud Build capability should they configure?

  1. Build trigger
  2. Manual approval only
  3. Cloud Storage lifecycle rule
  4. Cloud Trace span

Correct Answer: 1

Explanation

Cloud Build triggers automatically start builds when configured source events occur. A trigger can be associated with a repository and configured to respond to events such as pushes to a particular branch. The trigger can then invoke the specified build configuration to compile, test, package, or deploy the application. A manual approval mechanism does not itself detect repository changes, while Storage lifecycle rules manage object retention and Trace spans represent application execution information. A Cloud Build trigger is therefore the appropriate mechanism for automating builds based on source-control events.

Question 76

A service deployed to Cloud Run performs several independent outbound API calls during one request. The calls do not depend on one another, and reducing overall latency is important. What application technique can help improve response time?

  1. Execute every call sequentially
  2. Run independent operations concurrently
  3. Disable request authentication
  4. Increase log verbosity

Correct Answer: 2

Explanation

Independent outbound operations can often be executed concurrently rather than sequentially. When a request requires several unrelated API calls, parallel execution can reduce total waiting time because the application does not have to wait for each operation to finish before starting the next one. The actual implementation depends on the programming language and client libraries, and developers should still respect downstream quotas and connection limits. Sequential execution may unnecessarily increase latency, while disabling authentication or increasing log verbosity does not improve the underlying request execution pattern.

Question 77

An application uses Firestore and must update multiple related documents so that either every change succeeds or none of them becomes visible. Which Firestore capability should the developer use?

  1. Document export
  2. Collection indexing only
  3. Atomic transaction
  4. Cloud Scheduler

Correct Answer: 3

Explanation

Firestore transactions provide atomic operations across multiple documents when the application needs a consistent all-or-nothing update. A transaction reads the required documents, performs the necessary calculations, and writes changes while Firestore checks for conflicting updates. If the transaction cannot safely complete, the operation can be retried or fail without partially applying the intended transaction changes. Document exports are intended for data movement, indexes support query performance, and Cloud Scheduler handles scheduled execution. An atomic transaction is therefore appropriate when related Firestore updates must maintain consistency together.

Question 78

A team wants to measure CPU and memory behavior continuously in a production application to identify performance bottlenecks without adding extensive custom instrumentation. Which Google Cloud service is designed for continuous application profiling?

  1. Cloud Profiler
  2. Cloud Storage
  3. Cloud Tasks
  4. API Gateway

Correct Answer: 1

Explanation

Cloud Profiler is designed to continuously collect performance profiles from supported applications, helping developers identify where CPU time and memory are being consumed. Profiling information can reveal expensive functions, inefficient code paths, and resource-intensive operations that may not be obvious from application logs alone. Cloud Storage provides object storage, Cloud Tasks manages asynchronous task queues, and API Gateway manages APIs. Profiler is therefore the Google Cloud service specifically intended to help developers investigate application performance characteristics continuously in production environments.

Question 79

A team is deploying a new version of a service and wants a small percentage of production traffic to reach the new version before increasing its exposure. Which deployment strategy should the team implement?

  1. Full replacement immediately
  2. Canary deployment
  3. Permanent shutdown
  4. Manual database export

Correct Answer: 2

Explanation

A canary deployment gradually introduces a new application version to production by directing a limited portion of traffic to it initially. The team can monitor application behavior, errors, latency, and other operational indicators before increasing traffic to the new version. This reduces the scope of an unexpected problem compared with immediately sending all production traffic to the new release. A full replacement exposes the entire workload at once, while database export and service shutdown do not provide gradual application rollout. Canary deployment therefore supports controlled progressive release management.

Question 80

A developer creates a Cloud Run service that receives concurrent requests. Each request performs CPU-intensive work, and testing shows that high concurrency causes individual requests to slow significantly. Which Cloud Run setting should the developer evaluate to control how many requests are handled simultaneously by each instance?

  1. Maximum object size
  2. Service account key lifetime
  3. Container concurrency
  4. DNS propagation interval

Correct Answer: 3

Explanation

Cloud Run concurrency controls the maximum number of requests that a single container instance can handle simultaneously. For CPU-intensive workloads, excessive concurrency can cause requests to compete for available CPU and increase individual request latency. Reducing the concurrency setting can allow instances to focus resources on fewer requests at a time, although this may increase the number of instances required under load. Maximum object size, credential lifetime, and DNS propagation do not determine how many requests a Cloud Run instance processes concurrently. Container concurrency is therefore the relevant setting to evaluate.