Google Professional Cloud Developer Practice Test 52
Question 510
A service scales out too quickly because concurrency is set below what its asynchronous handler can safely support. The team is choosing a sustainable solution. Which design best meets the stated requirement without broad unrelated changes? Select ONE best answer.
- Use stable matching selectors and Pod labels so the Kubernetes controller owns the intended replicas.
- Assign a dedicated execution service account with the narrow roles needed for outbound service access.
- Use an authenticated Pub/Sub push subscription with a scoped service account and target audience.
- Set coordinated CPU, memory, and concurrency limits based on profiling rather than tuning a single value in isolation.
Explanation
Correct Answer
D:Set coordinated CPU, memory, and concurrency limits based on profiling rather than tuning a single value in isolation. In this scenario, a service scales out too quickly because concurrency is set below what its asynchronous handler can safely support. Before rollout, inspect memory consumption per active request, vCPU settings, concurrency, instance count, and tail latency.
Incorrect Answers
A:Use stable matching selectors and Pod labels so the Kubernetes controller owns the intended replicas. It cannot substitute for the required control: set coordinated CPU, memory, and concurrency limits based on profiling rather than tuning a single value in isolation.
B:Assign a dedicated execution service account with the narrow roles needed for outbound service access. This design addresses Cloud Run execution identity attachment, where the deployed execution identity controls Google API permissions from a Cloud Run workload; user identities and deployer privileges are separate. It cannot substitute for the required control: set coordinated CPU, memory, and concurrency limits based on profiling rather than tuning a single value in isolation.
C:Use an authenticated Pub/Sub push subscription with a scoped service account and target audience. This design addresses Pub/Sub push to Cloud Run authentication, where Pub/Sub push delivery can use an OIDC token for authenticated Cloud Run invocation; access is not established by topic ownership alone. It cannot substitute for the required control: set coordinated CPU, memory, and concurrency limits based on profiling rather than tuning a single value in isolation.
Question 511
A service scales out too quickly because concurrency is set below what its asynchronous handler can safely support. An approved limited change can be tested in a safe environment. Which implementation action most directly addresses this scenario? Select ONE best answer.
- Define startup order where supported and validate a request that depends on the sidecar without exposing its port publicly.
- Create validated service endpoints and network entry rules, then test authorized internal and external routes.
- Apply a representative HPA target and observe replica changes during controlled load increases and decreases.
- Test representative large requests at proposed concurrency values and adjust resource settings or application buffering.
Explanation
Correct Answer
D:Test representative large requests at proposed concurrency values and adjust resource settings or application buffering. In this scenario, a service scales out too quickly because concurrency is set below what its asynchronous handler can safely support. Validate the change by checking that requests complete within the memory budget while measured instance usage and latency remain acceptable.
Incorrect Answers
A:Define startup order where supported and validate a request that depends on the sidecar without exposing its port publicly. This action changes a different concern, Cloud Run sidecar container dependency. It addresses a different dependency from cloud run memory and concurrency coordination.
B:Create validated service endpoints and network entry rules, then test authorized internal and external routes. This action changes a different concern, GKE Service and ingress exposure. It addresses a different dependency from cloud run memory and concurrency coordination.
C:Apply a representative HPA target and observe replica changes during controlled load increases and decreases. This action changes a different concern, GKE Horizontal Pod Autoscaler metrics. It addresses a different dependency from cloud run memory and concurrency coordination.
Question 512
A service scales out too quickly because concurrency is set below what its asynchronous handler can safely support. The team has tried a correction. Which measurable outcome most directly demonstrates that this issue is resolved? Select ONE best answer.
- First-request latency meets requirements with a documented tradeoff in warm capacity cost.
- The Pod completes startup and later health failures are still detected without premature restarts.
- Replica scaling follows the target utilization and keeps application capacity within tested bounds.
- Requests complete within the memory budget while measured instance usage and latency remain acceptable.
Explanation
Correct Answer
D:Requests complete within the memory budget while measured instance usage and latency remain acceptable. In this scenario, a service scales out too quickly because concurrency is set below what its asynchronous handler can safely support. The original diagnosis should have included this step: inspect memory consumption per active request, vCPU settings, concurrency, instance count, and tail latency.
Incorrect Answers
A:First-request latency meets requirements with a documented tradeoff in warm capacity cost. That result could support testing of minimum instances and cold-start tradeoffs: Cloud Run minimum instances can reduce cold starts but incur resource charges; the correct setting depends on measured demand and service objectives. The reported condition is about cloud run memory and concurrency coordination, not this adjacent change.
B:The Pod completes startup and later health failures are still detected without premature restarts. That result could support testing of GKE startup probe for slow initialization: Kubernetes startup probes can suppress normal liveness and readiness checks during initialization, preventing startup time from being mistaken for failure. The reported condition is about cloud run memory and concurrency coordination, not this adjacent change.
C:Replica scaling follows the target utilization and keeps application capacity within tested bounds. The reported condition is about cloud run memory and concurrency coordination, not this adjacent change.
Question 513
A long-running export request regularly exceeds the configured Cloud Run timeout and the client sees a gateway timeout. Before choosing a remediation, which investigation best isolates the specific cause or unmet dependency? Select ONE best answer.
- Inspect request duration, configured timeout, downstream waits, retry behavior, and whether an immediate HTTP response is required.
- Inspect service versus revision configuration, environment variables, and which revision receives production traffic.
- Inspect the ingress process startup, host binding, runtime PORT variable, and container listening socket.
- Inspect network, subnet region, Direct VPC egress mode, firewall policy, and required destinations.
Explanation
Correct Answer
A:Inspect request duration, configured timeout, downstream waits, retry behavior, and whether an immediate HTTP response is required. This checks the actual operating conditions relevant to Cloud Run request timeout handling, rather than changing a service before the failure is understood.
Incorrect Answers
B:Inspect service versus revision configuration, environment variables, and which revision receives production traffic. Cloud Run revisions are immutable snapshots of code and configuration; environment updates create a new revision rather than editing old instances. This is not the decisive inspection for cloud run request timeout handling.
C:Inspect the ingress process startup, host binding, runtime PORT variable, and container listening socket. Cloud Run services expect the ingress container to listen on the configured port; process existence alone does not demonstrate request reachability. This is not the decisive inspection for cloud run request timeout handling.
D:Inspect network, subnet region, Direct VPC egress mode, firewall policy, and required destinations. Cloud Run VPC egress policy changes outbound routing; IAM, firewall and NAT controls still determine actual reachability. This is not the decisive inspection for cloud run request timeout handling.
Question 514
A long-running export request regularly exceeds the configured Cloud Run timeout and the client sees a gateway timeout. The team is choosing a sustainable solution. Which design best meets the stated requirement without broad unrelated changes? Select ONE best answer.
- Use supported request timeouts for bounded synchronous work and dispatch long jobs to a durable asynchronous workflow.
- Use Cloud Run source deployment with the appropriate build pipeline and explicitly account for the resulting container artifact.
- Set Cloud Run ingress exposure and IAM invocation permissions to match whether the service is internal or public.
- Use a revision tag for controlled targeted testing while keeping production traffic allocation unchanged.
Explanation
Correct Answer
A:Use supported request timeouts for bounded synchronous work and dispatch long jobs to a durable asynchronous workflow. Cloud Run request timeouts bound synchronous request handling; raising a deadline is not a durable background processing strategy. Before rollout, inspect request duration, configured timeout, downstream waits, retry behavior, and whether an immediate HTTP response is required.
Incorrect Answers
B:Use Cloud Run source deployment with the appropriate build pipeline and explicitly account for the resulting container artifact. That may help elsewhere, but it does not make the change required for cloud run request timeout handling.
C:Set Cloud Run ingress exposure and IAM invocation permissions to match whether the service is internal or public. This design addresses Cloud Run ingress restriction, where ingress controls which network paths can reach Cloud Run; IAM controls who may invoke it, and both policies can be necessary. That may help elsewhere, but it does not make the change required for cloud run request timeout handling.
D:Use a revision tag for controlled targeted testing while keeping production traffic allocation unchanged. This design addresses tagged Cloud Run revision validation, where revision tags provide direct revision access for testing; they do not inherently shift regular service URL traffic. That may help elsewhere, but it does not make the change required for cloud run request timeout handling.
Question 515
A long-running export request regularly exceeds the configured Cloud Run timeout and the client sees a gateway timeout. An approved limited change can be tested in a safe environment. Which implementation action most directly addresses this scenario? Select ONE best answer.
- Configure the cron schedule and OIDC identity, then run a one-off schedule test against the intended endpoint.
- Configure and test the trigger against a matching object creation and a deliberately excluded update.
- Configure a realistic request deadline and enqueue a long-running export with status tracking instead of holding the request open.
- Correct the manifest and apply it to a staging namespace, then compare desired and available Pods.
Explanation
Correct Answer
C:Configure a realistic request deadline and enqueue a long-running export with status tracking instead of holding the request open. Cloud Run request timeouts bound synchronous request handling; raising a deadline is not a durable background processing strategy. Validate the change by checking that interactive requests terminate predictably while long jobs complete independently with verifiable status.
Incorrect Answers
A:Configure the cron schedule and OIDC identity, then run a one-off schedule test against the intended endpoint. This action changes a different concern, Cloud Scheduler invoking a private service. A more direct response is to configure a realistic request deadline and enqueue a long-running export with status tracking instead of holding the request open.
B:Configure and test the trigger against a matching object creation and a deliberately excluded update. This action changes a different concern, eventarc-triggered Cloud Run handler. A more direct response is to configure a realistic request deadline and enqueue a long-running export with status tracking instead of holding the request open.
D:Correct the manifest and apply it to a staging namespace, then compare desired and available Pods. This action changes a different concern, GKE Deployment replicas and selectors. A more direct response is to configure a realistic request deadline and enqueue a long-running export with status tracking instead of holding the request open.
Question 516
A long-running export request regularly exceeds the configured Cloud Run timeout and the client sees a gateway timeout. The team has tried a correction. Which measurable outcome most directly demonstrates that this issue is resolved? Select ONE best answer.
- Both destination classes follow the approved routes and network controls without leaking private endpoints.
- The workload uses short-lived authorized identity and can access only intended buckets without key material in manifests.
- Interactive requests terminate predictably while long jobs complete independently with verifiable status.
- Production continues with approved configuration until the new revision is explicitly promoted.
Explanation
Correct Answer
C:Interactive requests terminate predictably while long jobs complete independently with verifiable status. This is evidence that the particular acceptance condition for Cloud Run request timeout handling has been met, rather than a general availability metric. The original diagnosis should have included this step: inspect request duration, configured timeout, downstream waits, retry behavior, and whether an immediate HTTP response is required.
Incorrect Answers
A:Both destination classes follow the approved routes and network controls without leaking private endpoints. That result could support testing of Cloud Run Direct VPC egress configuration: Cloud Run VPC egress policy changes outbound routing; IAM, firewall and NAT controls still determine actual reachability. The case instead calls for the following: interactive requests terminate predictably while long jobs complete independently with verifiable status.
B:The workload uses short-lived authorized identity and can access only intended buckets without key material in manifests. That result could support testing of GKE pod identity without key files: GKE workload identity maps Kubernetes principals to Google Cloud permissions without requiring embedded long-lived service account JSON keys. The case instead calls for the following: interactive requests terminate predictably while long jobs complete independently with verifiable status.
D:Production continues with approved configuration until the new revision is explicitly promoted. That result could support testing of Cloud Run environment configuration revisions: Cloud Run revisions are immutable snapshots of code and configuration; environment updates create a new revision rather than editing old instances. The case instead calls for the following: interactive requests terminate predictably while long jobs complete independently with verifiable status.
Question 517
A developer increases timeout indefinitely instead of separating work that can be processed asynchronously. Before choosing a remediation, which investigation best isolates the specific cause or unmet dependency? Select ONE best answer.
- Inspect revision service account, actual access tokens, target resource permissions, and who invokes the service.
- Inspect request duration, configured timeout, downstream waits, retry behavior, and whether an immediate HTTP response is required.
- Inspect Deployment selectors, Pod template labels, desired replicas, and rollout status.
- Inspect memory consumption per active request, vCPU settings, concurrency, instance count, and tail latency.
Explanation
Correct Answer
B:Inspect request duration, configured timeout, downstream waits, retry behavior, and whether an immediate HTTP response is required. This checks the actual operating conditions relevant to Cloud Run request timeout handling, rather than changing a service before the failure is understood. Before choosing a remediation, which investigation best isolates the specific cause or unmet dependency.
Incorrect Answers
A:Inspect revision service account, actual access tokens, target resource permissions, and who invokes the service. The deployed execution identity controls Google API permissions from a Cloud Run workload; user identities and deployer privileges are separate. It does not isolate the cloud run request timeout handling issue described.
C:Inspect Deployment selectors, Pod template labels, desired replicas, and rollout status. Kubernetes label selectors bind controllers and Services to Pods; mismatched labels break management and routing regardless of image health. It does not isolate the cloud run request timeout handling issue described.
D:Inspect memory consumption per active request, vCPU settings, concurrency, instance count, and tail latency. Per-instance concurrent work multiplies runtime resource demand; autoscaling does not prevent an individual overloaded container from exhausting memory. It does not isolate the cloud run request timeout handling issue described.
Question 518
A developer increases timeout indefinitely instead of separating work that can be processed asynchronously. The team is choosing a sustainable solution. Which design best meets the stated requirement without broad unrelated changes? Select ONE best answer.
- Use an authenticated Pub/Sub push subscription with a scoped service account and target audience.
- Add a startup probe that gives slow applications an explicit bounded initialization window before normal probes run.
- Use readiness to control serving eligibility and liveness only to restart genuinely unhealthy containers.
- Use supported request timeouts for bounded synchronous work and dispatch long jobs to a durable asynchronous workflow.
Explanation
Correct Answer
D:Use supported request timeouts for bounded synchronous work and dispatch long jobs to a durable asynchronous workflow. In this scenario, a developer increases timeout indefinitely instead of separating work that can be processed asynchronously. Before rollout, inspect request duration, configured timeout, downstream waits, retry behavior, and whether an immediate HTTP response is required.
Incorrect Answers
A:Use an authenticated Pub/Sub push subscription with a scoped service account and target audience. This design addresses Pub/Sub push to Cloud Run authentication, where Pub/Sub push delivery can use an OIDC token for authenticated Cloud Run invocation; access is not established by topic ownership alone. It addresses a different dependency from cloud run request timeout handling.
B:Add a startup probe that gives slow applications an explicit bounded initialization window before normal probes run. This design addresses GKE startup probe for slow initialization, where Kubernetes startup probes can suppress normal liveness and readiness checks during initialization, preventing startup time from being mistaken for failure. It addresses a different dependency from cloud run request timeout handling.
C:Use readiness to control serving eligibility and liveness only to restart genuinely unhealthy containers. This design addresses GKE readiness versus liveness probes, where readiness removes a Pod from eligible Service endpoints; liveness triggers restarts and therefore needs a different failure definition. It addresses a different dependency from cloud run request timeout handling.
Question 519
A developer increases timeout indefinitely instead of separating work that can be processed asynchronously. An approved limited change can be tested in a safe environment. Which implementation action most directly addresses this scenario? Select ONE best answer.
- Update application startup to honor PORT, bind appropriately, and test the image with the actual runtime contract.
- Assign a tag to the candidate revision and run authenticated regression checks against its tag URL.
- Configure a realistic request deadline and enqueue a long-running export with status tracking instead of holding the request open.
- Test representative large requests at proposed concurrency values and adjust resource settings or application buffering.
Explanation
Correct Answer
C:Configure a realistic request deadline and enqueue a long-running export with status tracking instead of holding the request open. In this scenario, a developer increases timeout indefinitely instead of separating work that can be processed asynchronously. Validate the change by checking that interactive requests terminate predictably while long jobs complete independently with verifiable status.
Incorrect Answers
A:Update application startup to honor PORT, bind appropriately, and test the image with the actual runtime contract. This action changes a different concern, Cloud Run container listening port. The reported condition is about cloud run request timeout handling, not this adjacent change.
B:Assign a tag to the candidate revision and run authenticated regression checks against its tag URL. This action changes a different concern, tagged Cloud Run revision validation. The reported condition is about cloud run request timeout handling, not this adjacent change.
D:Test representative large requests at proposed concurrency values and adjust resource settings or application buffering. This action changes a different concern, Cloud Run memory and concurrency coordination. The reported condition is about cloud run request timeout handling, not this adjacent change.
Question 520
A developer increases timeout indefinitely instead of separating work that can be processed asynchronously. The team has tried a correction. Which measurable outcome most directly demonstrates that this issue is resolved? Select ONE best answer.
- Interactive requests terminate predictably while long jobs complete independently with verifiable status.
- The handler runs for authorized matching events with valid delivery identity and no unnecessary invocations.
- The Pod completes startup and later health failures are still detected without premature restarts.
- First-request latency meets requirements with a documented tradeoff in warm capacity cost.
Explanation
Correct Answer
A:Interactive requests terminate predictably while long jobs complete independently with verifiable status. This is evidence that the particular acceptance condition for Cloud Run request timeout handling has been met, rather than a general availability metric. The original diagnosis should have included this step: inspect request duration, configured timeout, downstream waits, retry behavior, and whether an immediate HTTP response is required. A developer increases timeout indefinitely instead of separating work that can be processed asynchronously. The team has tried a correction.
Incorrect Answers
B:The handler runs for authorized matching events with valid delivery identity and no unnecessary invocations. That result could support testing of eventarc-triggered Cloud Run handler: Eventarc event routing requires compatible source filters, destination connectivity, and authorized trigger identity. Applying it first would leave cloud run request timeout handling unresolved.
C:The Pod completes startup and later health failures are still detected without premature restarts. That result could support testing of GKE startup probe for slow initialization: Kubernetes startup probes can suppress normal liveness and readiness checks during initialization, preventing startup time from being mistaken for failure. Applying it first would leave cloud run request timeout handling unresolved.
D:First-request latency meets requirements with a documented tradeoff in warm capacity cost. That result could support testing of minimum instances and cold-start tradeoffs: Cloud Run minimum instances can reduce cold starts but incur resource charges; the correct setting depends on measured demand and service objectives. Applying it first would leave cloud run request timeout handling unresolved.