>DevOps Interview KB

Google Cloud Platform Interview Questions

27 questions

GCP interview questions covering IAM (Workload Identity, service account security, org policy versus IAM), Cloud Functions (cold starts, Pub/Sub delivery semantics, Gen 1 versus Gen 2 concurrency), and Cloud Storage (access control, signed URLs, lifecycle management, exposure alerting) — scenario-driven, matching the same depth as this site's AWS coverage rather than treating GCP as an afterthought.

What's actually different between Cloud Functions Gen 1 and Gen 2, beyond just a version number?

IntermediateGcpCloud Functions6 min

A function migrated from Gen 1 to Gen 2 started returning occasionally-wrong results under load — what changed, and how do you fix it?

ExpertGcpCloud Functions8 min

A Cloud Function's p99 latency is dominated by cold starts under bursty traffic — how would you mitigate this, and what's the actual cost trade-off?

IntermediateGcpCloud Functions7 min

A Pub/Sub-triggered Cloud Function occasionally processes the same message twice — is this a bug, and how do you actually fix it?

IntermediateGcpCloud FunctionsPubsub7 min

A Cloud Function has been silently failing for days with no alert firing — what's typically missing in the observability setup, and how do you fix it?

IntermediateGcpCloud Functions6 min

A Cloud Function times out mid-execution after partially completing a multi-step operation — what state does it leave behind, and how do you design around this?

AdvancedGcpCloud Functions7 min

After adding a Serverless VPC Access connector to a Cloud Function, cold starts got noticeably slower — why, and is this avoidable?

AdvancedGcpCloud Functions6 min

How would you decide between Cloud Functions, Cloud Run, and GKE for a new workload, beyond just 'serverless is simpler'?

IntermediateGcpCloud FunctionsCloud Run7 min

A Cloud Function works perfectly with the Functions Framework locally but fails immediately in production — how do you systematically narrow down why?

IntermediateGcpCloud Functions7 min

How would you audit an entire GCP organization to find every principal holding Owner or Editor at the project level, before a security review?

AdvancedGcp7 min

Why is granting a GCP Editor or Owner basic role considered dangerous, and how do predefined and custom roles fix that?

BeginnerGcp6 min

How would you grant a contractor temporary access to a GCP project that automatically expires, without manually revoking it later?

IntermediateGcp6 min

A service account in Project A needs to read from a Cloud Storage bucket in Project B — how does IAM actually handle this cross-project access?

IntermediateGcp6 min

A GCP service account key was accidentally committed to a public repository — walk through your incident response, GCP-specific steps included.

AdvancedGcp8 min

How would you design least-privilege IAM for a Cloud Function that reads from Pub/Sub and writes to a specific Cloud Storage bucket?

IntermediateGcp6 min

A project has correct IAM roles, but you still need to guarantee no VM ever gets a public IP — is that an IAM problem, or something else?

IntermediateGcp6 min

How would you design a CI/CD pipeline's GCP authentication using service account impersonation instead of a downloaded key, and why is that safer?

AdvancedGcp7 min

A GKE workload needs to call a GCP API — should it use Workload Identity or a mounted service account key file, and why?

IntermediateGcpGke7 min

A browser-based app can list bucket contents but fails to upload directly to Cloud Storage with a CORS error — how do you fix the bucket's CORS configuration?

IntermediateGcpCloud Storage6 min

How would you choose between a dual-region and a multi-region Cloud Storage bucket for a workload needing regional resilience?

IntermediateGcpCloud Storage6 min

How would you design a fast, event-driven alerting system to catch an accidentally-public Cloud Storage bucket within minutes, GCP-native?

ExpertGcpCloud Storage8 min

How would you design Cloud Storage lifecycle rules to automatically reduce cost as objects age, without risking premature deletion of data still in use?

IntermediateGcpCloud Storage7 min

A bucket scan flags a bucket as publicly readable, but Public Access Prevention shows as enabled — how is that possible, and how do you investigate it?

AdvancedGcpCloud Storage7 min

A large file upload to Cloud Storage keeps failing partway through on an unreliable network — what does a resumable upload actually solve here?

BeginnerGcpCloud Storage6 min