Prepare and test your skills

Prepare and test your skills

Free sample question, answered and explained below. The Professional Data Engineer practice bank has 1,353 more like it. Try 10 free: instant score, no account.
An enterprise data engineering team operates an automated CI/CD pipeline in project-dev-cicd that deploys and executes nightly ETL workflows in project-analytics-prod. The pipeline must read source files from a dedicated Cloud Storage bucket and write processed tables into a specific BigQuery dataset in the analytics project.
Corporate security policy strictly forbids downloading and storing long-lived service account JSON keys and mandates least-privilege resource scoping.
How should you configure Cloud IAM and service account permissions to fulfill these requirements?
roles/bigquery.admin and roles/storage.admin directly at the project level in project-analytics-prod using cross-project IAM bindings.Directly binding administrative predefined roles (roles/bigquery.admin and roles/storage.admin) at the project level grants comprehensive management access over all BigQuery and Cloud Storage assets across the entire target project.
The pipeline was an administrative infrastructure-as-code automation tasked with managing project-wide BigQuery configurations and storage life-cycle rules.
project-analytics-prod with the basic roles/editor role. Grant the CI/CD pipeline service account the roles/iam.serviceAccountUser role on project-analytics-prod.The Editor (roles/editor) role is a legacy basic role granting broad read, modify, and delete access to nearly all Google Cloud resources within a project. The Service Account User (roles/iam.serviceAccountUser) role permits a principal to attach a service account to a compute resource (such as Compute Engine or Cloud Run functions).
roles/editor gives unrestricted control over all datasets, tables, buckets, and compute infrastructure in project-analytics-prod, far exceeding the required scope.roles/iam.serviceAccountUser does not grant permission to generate short-lived OAuth 2.0 access tokens via API impersonation; that specifically requires roles/iam.serviceAccountTokenCreator.A developer needed to deploy and attach a service account directly to a new Compute Engine VM instance during manual infrastructure provisioning.
project-analytics-prod. Grant it roles/storage.objectViewer on the bucket, roles/bigquery.dataEditor on the target dataset, and roles/bigquery.jobUser on the project. Grant the pipeline service account roles/iam.serviceAccountTokenCreator on the dedicated service account.Service account impersonation is an IAM security pattern that allows an authenticated principal (such as a CI/CD runner service account) to temporarily generate short-lived OAuth 2.0 credentials and act on behalf of a target service account. Coupled with fine-grained predefined IAM roles, this approach enforces least privilege at specific resource hierarchy levels rather than across entire projects.
roles/iam.serviceAccountTokenCreator directly on the target service account, the CI/CD pipeline acquires ephemeral access tokens at runtime via the IAM Credentials API, completely eliminating the need for downloadable JSON service account keys.roles/storage.objectViewer specifically on the target Cloud Storage bucket and roles/bigquery.dataEditor on the specific BigQuery dataset restricts data access to only the necessary resources. The roles/bigquery.jobUser role granted at the project level provides the minimal permission required to execute query and load jobs without granting broad administrative privileges.project-analytics-prod from unauthorized reads and writes.project-analytics-prod, export a service account JSON key file, and store it encrypted in Secret Manager. Grant the pipeline service account roles/secretmanager.secretAccessor.This pattern generates a static, user-managed private key for a service account and stores the JSON payload within Secret Manager, allowing client applications with roles/secretmanager.secretAccessor to fetch and use the credential for authentication.
The external orchestrator ran entirely on-premises without support for Workload Identity Federation or direct IAM service account impersonation.
Answer them yourself and get your score the moment you finish. No account needed.
Full access includes
Keep the momentum going with these hand-picked practice scenarios
Last updated Validated