Google Professional Cloud Developer Practice Test 62
Question 610
A Pod is repeatedly evicted during contention because it has no meaningful resource requests and poor scheduling guarantees. The team is choosing a sustainable solution. Which design best meets the stated requirement without broad unrelated changes? Select ONE best answer.
- Set resource requests for scheduling needs and limits for safe containment based on observed workload usage.
- Use Workload Identity Federation for GKE with least-privilege permissions rather than injecting static Google private keys.
- Rollback by restoring traffic to an immutable previously healthy revision while investigating the new release.
- Use an authenticated Pub/Sub push subscription with a scoped service account and target audience.
Explanation
Correct Answer
A:Set resource requests for scheduling needs and limits for safe containment based on observed workload usage. The expected outcome is that workloads schedule predictably and remain below reasonable limits without starving neighboring applications. Before rollout, inspect CPU and memory use distributions, scheduling requests, limits, and termination reasons.
Incorrect Answers
B:Use Workload Identity Federation for GKE with least-privilege permissions rather than injecting static Google private keys. This design addresses GKE pod identity without key files, where GKE workload identity maps Kubernetes principals to Google Cloud permissions without requiring embedded long-lived service account JSON keys. The reported condition is about gke resource requests and limits, not this adjacent change.
C:Rollback by restoring traffic to an immutable previously healthy revision while investigating the new release. This design addresses Cloud Run revision rollback strategy, where Cloud Run rollbacks manipulate traffic allocation among existing revisions rather than rewriting the contents of a released revision. The reported condition is about gke resource requests and limits, not this adjacent change.
D: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. The reported condition is about gke resource requests and limits, not this adjacent change.
Question 611
A Pod is repeatedly evicted during contention because it has no meaningful resource requests and poor scheduling guarantees. An approved limited change can be tested in a safe environment. Which implementation action most directly addresses this scenario? Select ONE best answer.
- Grant scoped invocation rights and send a correctly targeted ID token from the calling workload.
- Define separate appropriate probes and test an unready-but-running Pod and a truly deadlocked process.
- Update Pod resource specifications and test load under representative cluster contention.
- Configure push authentication and verify a test message reaches the private Cloud Run handler once under normal conditions.
Explanation
Correct Answer
C:Update Pod resource specifications and test load under representative cluster contention. Kubernetes requests influence scheduling and resource guarantees, while limits bound usage and can cause throttling or out-of-memory termination. Validate the change by checking that workloads schedule predictably and remain below reasonable limits without starving neighboring applications.
Incorrect Answers
A:Grant scoped invocation rights and send a correctly targeted ID token from the calling workload. This action changes a different concern, authenticated Cloud Run invocation. Applying it first would leave gke resource requests and limits unresolved.
B:Define separate appropriate probes and test an unready-but-running Pod and a truly deadlocked process. This action changes a different concern, GKE readiness versus liveness probes. Applying it first would leave gke resource requests and limits unresolved.
D:Configure push authentication and verify a test message reaches the private Cloud Run handler once under normal conditions. This action changes a different concern, Pub/Sub push to Cloud Run authentication. Applying it first would leave gke resource requests and limits unresolved.
Question 612
A Pod is repeatedly evicted during contention because it has no meaningful resource requests and poor scheduling guarantees. 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.
- Workloads schedule predictably and remain below reasonable limits without starving neighboring applications.
- Both destination classes follow the approved routes and network controls without leaking private endpoints.
- The Deployment maintains the required replicas with labels recognized by its controller and Service.
Explanation
Correct Answer
B:Workloads schedule predictably and remain below reasonable limits without starving neighboring applications. This is evidence that the particular acceptance condition for GKE resource requests and limits has been met, rather than a general availability metric. The original diagnosis should have included this step: inspect CPU and memory use distributions, scheduling requests, limits, and termination reasons.
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. That may help elsewhere, but it does not make the change required for gke resource requests and limits.
C: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. That may help elsewhere, but it does not make the change required for gke resource requests and limits.
D:The Deployment maintains the required replicas with labels recognized by its controller and Service. It would not establish the success condition for GKE resource requests and limits. That may help elsewhere, but it does not make the change required for gke resource requests and limits.
Question 613
A workload is killed for memory overuse after its container exceeds an overly tight memory limit under normal load. Before choosing a remediation, which investigation best isolates the specific cause or unmet dependency? Select ONE best answer.
- Inspect schedule expression, time zone, target URL, job identity, and endpoint invocation policy.
- Inspect network, subnet region, Direct VPC egress mode, firewall policy, and required destinations.
- Inspect CPU and memory use distributions, scheduling requests, limits, and termination reasons.
- Inspect Pod ServiceAccount, workload identity pool principal, IAM bindings, and token availability inside the Pod.
Explanation
Correct Answer
C:Inspect CPU and memory use distributions, scheduling requests, limits, and termination reasons. This checks the actual operating conditions relevant to GKE resource requests and limits, rather than changing a service before the failure is understood. A focused follow-up is to update Pod resource specifications and test load under representative cluster contention. Before choosing a remediation, which investigation best isolates the specific cause or unmet dependency.
Incorrect Answers
A:Inspect schedule expression, time zone, target URL, job identity, and endpoint invocation policy. Cloud Scheduler triggers work on a schedule, while Cloud Run request containers are not a reliable place to run an always-on system cron daemon. The more informative check is to inspect CPU and memory use distributions, scheduling requests, limits, and termination reasons.
B: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. The more informative check is to inspect CPU and memory use distributions, scheduling requests, limits, and termination reasons.
D:Inspect Pod ServiceAccount, workload identity pool principal, IAM bindings, and token availability inside the Pod. GKE workload identity maps Kubernetes principals to Google Cloud permissions without requiring embedded long-lived service account JSON keys. The more informative check is to inspect CPU and memory use distributions, scheduling requests, limits, and termination reasons.
Question 614
A workload is killed for memory overuse after its container exceeds an overly tight memory limit under normal load. The team is choosing a sustainable solution. Which design best meets the stated requirement without broad unrelated changes? Select ONE best answer.
- Use a revision tag for controlled targeted testing while keeping production traffic allocation unchanged.
- Use Cloud Run source deployment with the appropriate build pipeline and explicitly account for the resulting container artifact.
- Use Workload Identity Federation for GKE with least-privilege permissions rather than injecting static Google private keys.
- Set resource requests for scheduling needs and limits for safe containment based on observed workload usage.
Explanation
Correct Answer
D:Set resource requests for scheduling needs and limits for safe containment based on observed workload usage. The expected outcome is that workloads schedule predictably and remain below reasonable limits without starving neighboring applications. Before rollout, inspect CPU and memory use distributions, scheduling requests, limits, and termination reasons. A workload is killed for memory overuse after its container exceeds an overly tight memory limit under normal load. The team is choosing a sustainable solution.
Incorrect Answers
A: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. The case instead calls for the following: set resource requests for scheduling needs and limits for safe containment based on observed workload usage.
B:Use Cloud Run source deployment with the appropriate build pipeline and explicitly account for the resulting container artifact. For this case, Kubernetes requests influence scheduling and resource guarantees, while limits bound usage and can cause throttling or out-of-memory termination. The case instead calls for the following: set resource requests for scheduling needs and limits for safe containment based on observed workload usage.
C:Use Workload Identity Federation for GKE with least-privilege permissions rather than injecting static Google private keys. This design addresses GKE pod identity without key files, where 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: set resource requests for scheduling needs and limits for safe containment based on observed workload usage.
Question 615
A workload is killed for memory overuse after its container exceeds an overly tight memory limit under normal load. An approved limited change can be tested in a safe environment. Which implementation action most directly addresses this scenario? Select ONE best answer.
- Configure and test startup, readiness and liveness probes with a deliberately slow initialization path.
- Configure and test the trigger against a matching object creation and a deliberately excluded update.
- Update Pod resource specifications and test load under representative cluster contention.
- Deploy the configuration to a tagged or no-traffic revision and verify runtime values before moving traffic.
Explanation
Correct Answer
C:Update Pod resource specifications and test load under representative cluster contention. Kubernetes requests influence scheduling and resource guarantees, while limits bound usage and can cause throttling or out-of-memory termination. Validate the change by checking that workloads schedule predictably and remain below reasonable limits without starving neighboring applications. An approved limited change can be tested in a safe environment.
Incorrect Answers
A:Configure and test startup, readiness and liveness probes with a deliberately slow initialization path. This action changes a different concern, GKE startup probe for slow initialization. It cannot substitute for the required control: update Pod resource specifications and test load under representative cluster contention.
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. It cannot substitute for the required control: update Pod resource specifications and test load under representative cluster contention.
D:Deploy the configuration to a tagged or no-traffic revision and verify runtime values before moving traffic. This action changes a different concern, Cloud Run environment configuration revisions. It cannot substitute for the required control: update Pod resource specifications and test load under representative cluster contention.
Question 616
A workload is killed for memory overuse after its container exceeds an overly tight memory limit under normal load. The team has tried a correction. Which measurable outcome most directly demonstrates that this issue is resolved? Select ONE best answer.
- Traffic avoids unready Pods without needless container restarts during normal initialization.
- Workloads schedule predictably and remain below reasonable limits without starving neighboring applications.
- The service accesses only approved data and does not inherit a developer's broad personal permissions.
- The revision becomes ready and accepts HTTP requests on the port designated by the hosting platform.
Explanation
Correct Answer
B:Workloads schedule predictably and remain below reasonable limits without starving neighboring applications. This is evidence that the particular acceptance condition for GKE resource requests and limits has been met, rather than a general availability metric. The original diagnosis should have included this step: inspect CPU and memory use distributions, scheduling requests, limits, and termination reasons. A workload is killed for memory overuse after its container exceeds an overly tight memory limit under normal load. The team has tried a correction.
Incorrect Answers
A:Traffic avoids unready Pods without needless container restarts during normal initialization. That result could support testing of GKE readiness versus liveness probes: Readiness removes a Pod from eligible Service endpoints; liveness triggers restarts and therefore needs a different failure definition. It addresses a different dependency from gke resource requests and limits.
C:The service accesses only approved data and does not inherit a developer's broad personal permissions. That result could support testing of Cloud Run execution identity attachment: The deployed execution identity controls Google API permissions from a Cloud Run workload; user identities and deployer privileges are separate. It addresses a different dependency from gke resource requests and limits.
D:The revision becomes ready and accepts HTTP requests on the port designated by the hosting platform. It would not establish the success condition for GKE resource requests and limits. It addresses a different dependency from gke resource requests and limits.
Question 617
A Deployment has healthy Pods but customers cannot reach it because there is no suitable Kubernetes Service or ingress path. Before choosing a remediation, which investigation best isolates the specific cause or unmet dependency? Select ONE best answer.
- Inspect revision history, current traffic percentages, error rates, and verified rollback candidates.
- Inspect invocation authentication setting, caller principal, audience in the ID token, and Cloud Run Invoker binding.
- Inspect Pod labels, Service selectors, Service type, ingress configuration, and security boundary requirements.
- Inspect CPU and memory use distributions, scheduling requests, limits, and termination reasons.
Explanation
Correct Answer
C:Inspect Pod labels, Service selectors, Service type, ingress configuration, and security boundary requirements. This checks the actual operating conditions relevant to GKE Service and ingress exposure, rather than changing a service before the failure is understood. A focused follow-up is to create validated service endpoints and network entry rules, then test authorized internal and external routes.
Incorrect Answers
A:Inspect revision history, current traffic percentages, error rates, and verified rollback candidates. Cloud Run rollbacks manipulate traffic allocation among existing revisions rather than rewriting the contents of a released revision. The relevant dependency is gke service and ingress exposure, which this inspection alone does not establish.
B:Inspect invocation authentication setting, caller principal, audience in the ID token, and Cloud Run Invoker binding. Private Cloud Run invocation requires both valid identity evidence and applicable IAM authorization; making it public is not a substitute. The relevant dependency is gke service and ingress exposure, which this inspection alone does not establish.
D:Inspect CPU and memory use distributions, scheduling requests, limits, and termination reasons. Kubernetes requests influence scheduling and resource guarantees, while limits bound usage and can cause throttling or out-of-memory termination. The relevant dependency is gke service and ingress exposure, which this inspection alone does not establish.
Question 618
A Deployment has healthy Pods but customers cannot reach it because there is no suitable Kubernetes Service or ingress path. The team is choosing a sustainable solution. Which design best meets the stated requirement without broad unrelated changes? Select ONE best answer.
- Add a startup probe that gives slow applications an explicit bounded initialization window before normal probes run.
- Assign a dedicated execution service account with the narrow roles needed for outbound service access.
- Use an appropriate Kubernetes Service and controlled ingress or load-balancer configuration for the required audience.
- Rollback by restoring traffic to an immutable previously healthy revision while investigating the new release.
Explanation
Correct Answer
C:Use an appropriate Kubernetes Service and controlled ingress or load-balancer configuration for the required audience. In this scenario, a Deployment has healthy Pods but customers cannot reach it because there is no suitable Kubernetes Service or ingress path. Before rollout, inspect Pod labels, Service selectors, Service type, ingress configuration, and security boundary requirements.
Incorrect Answers
A: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. Applying it first would leave gke service and ingress exposure unresolved.
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. Applying it first would leave gke service and ingress exposure unresolved.
D:Rollback by restoring traffic to an immutable previously healthy revision while investigating the new release. This design addresses Cloud Run revision rollback strategy, where Cloud Run rollbacks manipulate traffic allocation among existing revisions rather than rewriting the contents of a released revision. Applying it first would leave gke service and ingress exposure unresolved.
Question 619
A Deployment has healthy Pods but customers cannot reach it because there is no suitable Kubernetes Service or ingress path. An approved limited change can be tested in a safe environment. Which implementation action most directly addresses this scenario? Select ONE best answer.
- Define separate appropriate probes and test an unready-but-running Pod and a truly deadlocked process.
- Create validated service endpoints and network entry rules, then test authorized internal and external routes.
- Deploy a canary revision with the proposed network options and test private SQL and public API connectivity.
- Configure push authentication and verify a test message reaches the private Cloud Run handler once under normal conditions.
Explanation
Correct Answer
B:Create validated service endpoints and network entry rules, then test authorized internal and external routes. In this scenario, a Deployment has healthy Pods but customers cannot reach it because there is no suitable Kubernetes Service or ingress path. Validate the change by checking that healthy Pods receive traffic through the intended endpoint while private services remain unexposed.
Incorrect Answers
A:Define separate appropriate probes and test an unready-but-running Pod and a truly deadlocked process. This action changes a different concern, GKE readiness versus liveness probes. That may help elsewhere, but it does not make the change required for gke service and ingress exposure.
C:Deploy a canary revision with the proposed network options and test private SQL and public API connectivity. This action changes a different concern, Cloud Run Direct VPC egress configuration. That may help elsewhere, but it does not make the change required for gke service and ingress exposure.
D:Configure push authentication and verify a test message reaches the private Cloud Run handler once under normal conditions. This action changes a different concern, Pub/Sub push to Cloud Run authentication. That may help elsewhere, but it does not make the change required for gke service and ingress exposure.
Question 620
A Deployment has healthy Pods but customers cannot reach it because there is no suitable Kubernetes Service or ingress path. The team has tried a correction. Which measurable outcome most directly demonstrates that this issue is resolved? Select ONE best answer.
- Workloads schedule predictably and remain below reasonable limits without starving neighboring applications.
- Healthy Pods receive traffic through the intended endpoint while private services remain unexposed.
- The handler runs for authorized matching events with valid delivery identity and no unnecessary invocations.
- The application reads only authorized secret content and adopts updated credentials according to documented delivery behavior.
Explanation
Correct Answer
B:Healthy Pods receive traffic through the intended endpoint while private services remain unexposed. In this scenario, a Deployment has healthy Pods but customers cannot reach it because there is no suitable Kubernetes Service or ingress path. The original diagnosis should have included this step: inspect Pod labels, Service selectors, Service type, ingress configuration, and security boundary requirements.
Incorrect Answers
A:Workloads schedule predictably and remain below reasonable limits without starving neighboring applications. That result could support testing of GKE resource requests and limits: Kubernetes requests influence scheduling and resource guarantees, while limits bound usage and can cause throttling or out-of-memory termination. A more direct response is to recognize that healthy Pods receive traffic through the intended endpoint while private services remain unexposed.
C: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. A more direct response is to recognize that healthy Pods receive traffic through the intended endpoint while private services remain unexposed.
D:The application reads only authorized secret content and adopts updated credentials according to documented delivery behavior. It would not establish the success condition for GKE Service and ingress exposure. A more direct response is to recognize that healthy Pods receive traffic through the intended endpoint while private services remain unexposed.