Professional Data Engineer on Google Cloud Platform Professional Data Engineer Practice Test 40
Question 390
A production data pipeline has this problem: An external auditor needs a narrow view of invoice totals but cannot receive permissions on all underlying finance tables. Which solution MOST directly corrects it?
- Use managed workload identity or supported service-account impersonation with minimum privileges instead of repository-stored keys.
- Expose approved results using a BigQuery authorized view or supported authorized dataset configuration.
- Apply organization policy constraints and infrastructure review that prevent nonapproved data-resource locations.
- Create location-compatible datasets and jobs and enforce allowed-location governance where supported by organization policy.
Explanation
Correct Answer
B:The appropriate design is to expose approved results using a BigQuery authorized view or supported authorized dataset configuration. This addresses the exact constraint: An external auditor needs a narrow view of invoice totals but cannot receive permissions on all underlying finance tables. The underlying principle is that authorized views can share derived information without granting consumers direct access to every referenced base table. If omitted, granting base-table read permissions might leak individual invoice details not required by the audit. A direct acceptance test is: The auditor queries the authorized view successfully but direct queries against the base table are denied.
Incorrect Answers
A:This action fits a separate situation: A scheduled ingestion workload authenticates to Google Cloud with a long-lived service-account key embedded in a repository. There it would make sense to use managed workload identity or supported service-account impersonation with minimum privileges instead of repository-stored keys. It does not resolve this case, in which an external auditor needs a narrow view of invoice totals but cannot receive permissions on all underlying finance tables. The needed control is to expose approved results using a BigQuery authorized view or supported authorized dataset configuration.
C:This action fits a separate situation: A new data pipeline provisions resources in unrestricted locations although corporate policy specifies a small set of allowed regions. There it would make sense to apply organization policy constraints and infrastructure review that prevent nonapproved data-resource locations. It does not resolve this case, in which an external auditor needs a narrow view of invoice totals but cannot receive permissions on all underlying finance tables. The needed control is to expose approved results using a BigQuery authorized view or supported authorized dataset configuration.
D:This action fits a separate situation: A multinational organization must keep European patient datasets in an approved European location during processing and storage. There it would make sense to create location-compatible datasets and jobs and enforce allowed-location governance where supported by organization policy. It does not resolve this case, in which an external auditor needs a narrow view of invoice totals but cannot receive permissions on all underlying finance tables. The needed control is to expose approved results using a BigQuery authorized view or supported authorized dataset configuration.
Question 391
Consider a Google Cloud data engineering design: Two upstream teams publish JSON with different values and types for the same field called transaction_id. What action BEST meets the stated constraint?
- Agree a versioned event schema and producer contract, including compatibility and error-handling policy.
- Use Pub/Sub for durable event ingestion and an approved downstream streaming processor and analytical sink.
- Define immutable business event IDs and a deduplication boundary in the consumer and output design.
- Assign a dedicated ingestion service account with source-specific access and only required destination permissions.
Explanation
Correct Answer
A:The appropriate design is to agree a versioned event schema and producer contract, including compatibility and error-handling policy. This addresses the exact constraint: Two upstream teams publish JSON with different values and types for the same field called transaction_id. The underlying principle is that consistent source contracts prevent schema drift from appearing later as broken joins or lost records. If omitted, a producer release can break consumers when numeric IDs replace previously used strings. A direct acceptance test is: Contract tests reject the incompatible event and preserve a readable diagnostic of the rejected payload.
Incorrect Answers
B:This action fits a separate situation: Thousands of mobile clients send purchase events and product teams need near-real-time ingestion before asynchronous analytics. There it would make sense to use Pub/Sub for durable event ingestion and an approved downstream streaming processor and analytical sink. It does not resolve this case, in which two upstream teams publish JSON with different values and types for the same field called transaction_id. The needed control is to agree a versioned event schema and producer contract, including compatibility and error-handling policy.
C:This action fits a separate situation: A billing publisher retries submissions after timeouts and cannot tell whether the same event already entered the stream. There it would make sense to define immutable business event IDs and a deduplication boundary in the consumer and output design. It does not resolve this case, in which two upstream teams publish JSON with different values and types for the same field called transaction_id. The needed control is to agree a versioned event schema and producer contract, including compatibility and error-handling policy.
D:This action fits a separate situation: A new SaaS connector runs with developer credentials rather than a dedicated service identity during scheduled imports. There it would make sense to assign a dedicated ingestion service account with source-specific access and only required destination permissions. It does not resolve this case, in which two upstream teams publish JSON with different values and types for the same field called transaction_id. The needed control is to agree a versioned event schema and producer contract, including compatibility and error-handling policy.
Question 392
The engineering team ignores the recommended change: Set explicit recovery targets and rehearse backup restoration, connectivity and dependent pipeline startup. The current state is: A risk team claims disaster recovery readiness because Cloud SQL backups exist but nobody has tested a production-like restore. What is the greatest specific exposure?
- The database may prove unrecoverable or too slow to restore when a real regional disruption occurs.
- Workers may restart cleanly while an interval of sensor events is permanently omitted.
- An outdated dashboard may drive incorrect operational decisions despite an all-green job list.
- Inventory may be decremented without the corresponding ledger entry when the second update fails.
Explanation
Correct Answer
A:The specific residual risk is that the database may prove unrecoverable or too slow to restore when a real regional disruption occurs. The situation is: A risk team claims disaster recovery readiness because Cloud SQL backups exist but nobody has tested a production-like restore. The missing response is to set explicit recovery targets and rehearse backup restoration, connectivity and dependent pipeline startup. The engineering reason is that backup possession is not evidence that restoration will meet recovery-time and data-loss requirements. After remediation, verify: A timed restoration test demonstrates accepted recovery point and service-readiness objectives.
Incorrect Answers
B:This failure mode belongs chiefly to another situation: A streaming sensor pipeline has no checkpoint or progress tracking and loses messages when its worker pool restarts. Its tailored control is to select recoverable source and processing offsets and validate checkpoint or replay behavior for the managed pipeline. In the present situation the more direct exposure is that the database may prove unrecoverable or too slow to restore when a real regional disruption occurs.
C:This failure mode belongs chiefly to another situation: Daily dashboards appear green but arrive two hours late because the pipeline monitors only task success. Its tailored control is to track data freshness and completeness SLIs alongside job execution status and route threshold breaches. In the present situation the more direct exposure is that the database may prove unrecoverable or too slow to restore when a real regional disruption occurs.
D:This failure mode belongs chiefly to another situation: A BigQuery script updates inventory reservations and account ledgers but can leave one table updated if a later statement fails. Its tailored control is to use a supported BigQuery multi-statement transaction for the related DML operations and test rollback behavior. In the present situation the more direct exposure is that the database may prove unrecoverable or too slow to restore when a real regional disruption occurs.
Question 393
A production data pipeline has this problem: Developers and production schedulers currently share the same BigQuery dataset and can overwrite audited reporting tables. Which solution MOST directly corrects it?
- Apply BigQuery policy tags or supported column-level controls to withhold the restricted identity column from the analyst role.
- Configure supported Cloud KMS permissions for the relevant BigQuery encryption service identity and test key rotation procedures.
- Separate development and production data resources and authorize deploy-only service accounts for guarded promotion.
- Expose approved results using a BigQuery authorized view or supported authorized dataset configuration.
Explanation
Correct Answer
C:The appropriate design is to separate development and production data resources and authorize deploy-only service accounts for guarded promotion. This addresses the exact constraint: Developers and production schedulers currently share the same BigQuery dataset and can overwrite audited reporting tables. The underlying principle is that environment isolation reduces accidental cross-environment writes and limits the impact of development credentials. If omitted, a developer test can truncate the production reporting table or modify production data unexpectedly. A direct acceptance test is: A development identity can write to test datasets but cannot modify production tables without approved promotion.
Incorrect Answers
A:This action fits a separate situation: A customer-support dashboard needs customer city and purchase totals but must not disclose raw identity-document numbers. There it would make sense to apply BigQuery policy tags or supported column-level controls to withhold the restricted identity column from the analyst role. It does not resolve this case, in which developers and production schedulers currently share the same BigQuery dataset and can overwrite audited reporting tables. The needed control is to separate development and production data resources and authorize deploy-only service accounts for guarded promotion.
B:This action fits a separate situation: A healthcare dataset uses a customer-managed encryption key that the analytics service account cannot use after key permissions change. There it would make sense to configure supported Cloud KMS permissions for the relevant BigQuery encryption service identity and test key rotation procedures. It does not resolve this case, in which developers and production schedulers currently share the same BigQuery dataset and can overwrite audited reporting tables. The needed control is to separate development and production data resources and authorize deploy-only service accounts for guarded promotion.
D:This action fits a separate situation: An external auditor needs a narrow view of invoice totals but cannot receive permissions on all underlying finance tables. There it would make sense to expose approved results using a BigQuery authorized view or supported authorized dataset configuration. It does not resolve this case, in which developers and production schedulers currently share the same BigQuery dataset and can overwrite audited reporting tables. The needed control is to separate development and production data resources and authorize deploy-only service accounts for guarded promotion.
Question 394
A data engineer recommends: Redesign the row key using device or hash prefixes and validate distribution against typical range queries. It addresses: An IoT platform writes Bigtable rows with monotonically increasing time-leading keys and sees one overloaded tablet. What underlying principle explains the recommendation?
- Spanner is intended for horizontally scalable relational workloads requiring strong transactional consistency.
- Bigtable scales by contiguous key ranges, making poorly distributed sequential writes a hotspot risk.
- Lake-based SQL access can query external files while preserving separately managed storage and access boundaries.
- A low-latency cache can reduce repetitive database reads but should not replace durable authoritative writes.
Explanation
Correct Answer
B:The governing principle is that bigtable scales by contiguous key ranges, making poorly distributed sequential writes a hotspot risk. It explains why the team should redesign the row key using device or hash prefixes and validate distribution against typical range queries. The current problem is: An IoT platform writes Bigtable rows with monotonically increasing time-leading keys and sees one overloaded tablet. Without the safeguard, new tablets may not balance load while all recent events target the same row-key range. A suitable proof is: Key-space metrics show distributed writes with acceptable latency for required device-time scans.
Incorrect Answers
A:That principle applies primarily to a different design condition: A global financial service needs relational transactions and strongly consistent writes across geographically distributed users. There the relevant engineering response is to evaluate Cloud Spanner with supported regional or multi-region configuration and transaction design. For the given case, the controlling rationale is that bigtable scales by contiguous key ranges, making poorly distributed sequential writes a hotspot risk.
C:That principle applies primarily to a different design condition: A data lake stores governed Parquet objects in Cloud Storage and analysts want SQL access without copying every file into native tables. There the relevant engineering response is to evaluate supported BigLake or BigQuery external-table access with compatible governance and performance testing. For the given case, the controlling rationale is that bigtable scales by contiguous key ranges, making poorly distributed sequential writes a hotspot risk.
D:That principle applies primarily to a different design condition: An API repeatedly reads a small set of product prices from a slower backing database with heavy peak traffic. There the relevant engineering response is to use Memorystore as a managed cache with explicit TTL, invalidation and authoritative source-of-truth rules. For the given case, the controlling rationale is that bigtable scales by contiguous key ranges, making poorly distributed sequential writes a hotspot risk.
Question 395
A pipeline team implements the measure: Choose supported private connectivity and route throughput tests before bulk migration begins. Which result would provide the STRONGEST operational evidence of effectiveness?
- The transfer runs over the approved private path and measured throughput meets the migration plan.
- A dry-run cutover reconciles data and records the final replication lag within the outage target.
- Both systems produce matching audited revenue and customer counts for a defined reconciliation window.
- The migration inventory and access logs show every staging and destination resource uses an allowed location.
Explanation
Correct Answer
A:This is the decisive test result: The transfer runs over the approved private path and measured throughput meets the migration plan. It directly validates the implementation to choose supported private connectivity and route throughput tests before bulk migration begins. The underlying case is: A migration copies large databases over a public route that violates internal network isolation requirements. This matters because migration networking must satisfy data protection requirements and enough sustained bandwidth to meet cutover timing. Without it, a public or underprovisioned transfer path can expose data and extend the migration beyond the agreed window.
Incorrect Answers
B:This is proof for a different safeguard: Assess Database Migration Service support and an initial load plus continuous replication cutover plan. That applies when a company moves a supported transactional database to Cloud SQL and needs a short final application outage. The present control instead requires the specific outcome: The transfer runs over the approved private path and measured throughput meets the migration plan.
C:This is proof for a different safeguard: Run parallel output validation and reconcile critical business totals by period before final switching. That applies when a retailer plans to cut over an enterprise data warehouse without comparing newly computed revenue metrics to the old system. The present control instead requires the specific outcome: The transfer runs over the approved private path and measured throughput meets the migration plan.
D:This is proof for a different safeguard: Inventory source, temporary staging, transfer and target resource locations and apply residency controls before migration. That applies when a bank's data warehouse relocation includes confidential records that cannot be staged in an unapproved country. The present control instead requires the specific outcome: The transfer runs over the approved private path and measured throughput meets the migration plan.
Question 396
The team is considering: Use dashboard access controls and approved report embedding or sharing settings tied to data permissions. The context is: An internal dashboard is broadly linked through a chat message although the underlying records contain confidential business forecasts. Which engineering principle is MOST relevant?
- Data sharing must account for geographic processing and storage constraints on both producer and consumer sides.
- De-identification must be applied to shared outputs as well as restricted source tables.
- Publishing a report link is not sufficient authorization to view the data it references.
- Temporary data sharing needs expiry controls rather than relying on manual memories to revoke privileges.
Explanation
Correct Answer
C:The governing principle is that publishing a report link is not sufficient authorization to view the data it references. It explains why the team should use dashboard access controls and approved report embedding or sharing settings tied to data permissions. The current problem is: An internal dashboard is broadly linked through a chat message although the underlying records contain confidential business forecasts. Without the safeguard, a forwarded URL can reveal unreleased forecasts if embedded credentials or public link settings bypass access controls. A suitable proof is: A nonmember opening the shared link is denied the protected report and underlying data.
Incorrect Answers
A:That principle applies primarily to a different design condition: A customer in a restricted region cannot receive its shared export in a dataset hosted outside the authorized jurisdiction. There the relevant engineering response is to plan location-compatible sharing and approved export paths before publishing the subscription. For the given case, the controlling rationale is that publishing a report link is not sufficient authorization to view the data it references.
B:That principle applies primarily to a different design condition: A dataset shared with contractors includes direct phone numbers that are not needed for their analytical report. There the relevant engineering response is to publish masked or tokenized fields and explicitly authorize any permitted unmasked roles. For the given case, the controlling rationale is that publishing a report link is not sufficient authorization to view the data it references.
D:That principle applies primarily to a different design condition: A temporary outside research contract should grant access to one dataset for thirty days, not indefinitely. There the relevant engineering response is to issue time-bounded governed access and automate revocation or periodic review of the sharing entitlement. For the given case, the controlling rationale is that publishing a report link is not sufficient authorization to view the data it references.
Question 397
A production review examines this scenario: A business wants batch product recommendations for every account and already maintains clean historical interactions in BigQuery. The team adopts: Evaluate an appropriate BigQuery ML model and scheduled batch prediction workflow with held-out ranking checks. Which test BEST establishes the control works?
- A scheduled prediction produces one scored record per eligible account and meets agreed relevance metrics.
- The same raw test entity produces matching approved feature vectors in offline and online paths.
- A held-out evaluation produces documented quality metrics and a traceable model version using the governed tables.
- An as-of-time validation finds no feature values timestamped after their prediction events.
Explanation
Correct Answer
A:This is the decisive test result: A scheduled prediction produces one scored record per eligible account and meets agreed relevance metrics. It directly validates the implementation to evaluate an appropriate BigQuery ML model and scheduled batch prediction workflow with held-out ranking checks. The underlying case is: A business wants batch product recommendations for every account and already maintains clean historical interactions in BigQuery. This matters because batch ML scoring should match product objectives and data availability rather than require online serving by default. Without it, a real-time endpoint may add cost without improving a once-per-day recommendation use case.
Incorrect Answers
B:This is proof for a different safeguard: Version feature transformations and validate training-serving parity before model promotion. That applies when an online model receives categorical features computed differently from the training query maintained in BigQuery. The present control instead requires the specific outcome: A scheduled prediction produces one scored record per eligible account and meets agreed relevance metrics.
C:This is proof for a different safeguard: Evaluate supported BigQuery ML training and evaluation on the governed analytical dataset. That applies when an analyst wants to predict customer churn from warehouse features without exporting the dataset into a separately managed training service. The present control instead requires the specific outcome: A scheduled prediction produces one scored record per eligible account and meets agreed relevance metrics.
D:This is proof for a different safeguard: Use time-aware feature joins and hold out future periods so training information precedes each prediction point. That applies when a fraud team joins customer transactions to labels generated weeks later and accidentally exposes future outcomes in training features. The present control instead requires the specific outcome: A scheduled prediction produces one scored record per eligible account and meets agreed relevance metrics.
Question 398
A production data pipeline has this problem: Analysts paste a confidential schema into an LLM and execute its generated BigQuery SQL without review or access checks. Which solution MOST directly corrects it?
- Choose supported exactly-once pipeline semantics where appropriate and enforce idempotent external writes by transaction identifier.
- Select recoverable source and processing offsets and validate checkpoint or replay behavior for the managed pipeline.
- Set explicit recovery targets and rehearse backup restoration, connectivity and dependent pipeline startup.
- Require approved prompting boundaries and dry runs or validation of generated queries under least-privilege identities.
Explanation
Correct Answer
D:The appropriate design is to require approved prompting boundaries and dry runs or validation of generated queries under least-privilege identities. This addresses the exact constraint: Analysts paste a confidential schema into an LLM and execute its generated BigQuery SQL without review or access checks. The underlying principle is that aI-assisted SQL generation still requires independent authorization, correctness and data-exposure controls. If omitted, a generated query may join restricted tables or produce invalid financial totals with a plausible narrative. A direct acceptance test is: An intentionally unauthorized generated statement is blocked and a known result is checked against a verified baseline.
Incorrect Answers
A:This action fits a separate situation: A payments pipeline switches to at-least-once processing but writes directly to an external system that cannot tolerate duplicates. There it would make sense to choose supported exactly-once pipeline semantics where appropriate and enforce idempotent external writes by transaction identifier. It does not resolve this case, in which analysts paste a confidential schema into an LLM and execute its generated BigQuery SQL without review or access checks. The needed control is to require approved prompting boundaries and dry runs or validation of generated queries under least-privilege identities.
B:This action fits a separate situation: A streaming sensor pipeline has no checkpoint or progress tracking and loses messages when its worker pool restarts. There it would make sense to select recoverable source and processing offsets and validate checkpoint or replay behavior for the managed pipeline. It does not resolve this case, in which analysts paste a confidential schema into an LLM and execute its generated BigQuery SQL without review or access checks. The needed control is to require approved prompting boundaries and dry runs or validation of generated queries under least-privilege identities.
C:This action fits a separate situation: A risk team claims disaster recovery readiness because Cloud SQL backups exist but nobody has tested a production-like restore. There it would make sense to set explicit recovery targets and rehearse backup restoration, connectivity and dependent pipeline startup. It does not resolve this case, in which analysts paste a confidential schema into an LLM and execute its generated BigQuery SQL without review or access checks. The needed control is to require approved prompting boundaries and dry runs or validation of generated queries under least-privilege identities.
Question 399
The design review proposes the following action: Prefer a managed Dataflow streaming design when Beam semantics and service constraints match the workload. The triggering condition is: A new streaming transformation can be implemented in either a custom Spark cluster or Dataflow with autoscaling, and operations has no cluster team. Which technical principle BEST justifies it?
- Batch loads are suitable when source files arrive in bounded intervals and minute-level latency is unnecessary.
- Choosing processing services must consider operational ownership and managed streaming capabilities as well as language preference.
- Skewed keys reduce parallelism because excessive state and work accumulate on one processing key.
- Poison messages need bounded isolation so a permanently unprocessable record does not destabilize healthy traffic.
Explanation
Correct Answer
B:The governing principle is that choosing processing services must consider operational ownership and managed streaming capabilities as well as language preference. It explains why the team should prefer a managed Dataflow streaming design when Beam semantics and service constraints match the workload. The current problem is: A new streaming transformation can be implemented in either a custom Spark cluster or Dataflow with autoscaling, and operations has no cluster team. Without the safeguard, a self-managed long-lived cluster may create avoidable patching, scaling and availability obligations. A suitable proof is: The managed pipeline handles a load surge and meets latency targets without manual node administration.
Incorrect Answers
A:That principle applies primarily to a different design condition: A logistics team receives daily CSV objects and wants a large validated table load without paying for per-event streaming. There the relevant engineering response is to use a scheduled or triggered Cloud Storage to BigQuery batch load job with explicit source schema and completion checks. For the given case, the controlling rationale is that choosing processing services must consider operational ownership and managed streaming capabilities as well as language preference.
C:That principle applies primarily to a different design condition: A distributed Apache Beam aggregation keys every payment into a single merchant ID and its throughput collapses. There the relevant engineering response is to detect hot keys and apply supported fanout or key-distribution strategies before final aggregation. For the given case, the controlling rationale is that choosing processing services must consider operational ownership and managed streaming capabilities as well as language preference.
D:That principle applies primarily to a different design condition: One malformed Pub/Sub payload is retried indefinitely and repeatedly blocks progress for a subscription consumer. There the relevant engineering response is to configure controlled retry limits and an authorized dead-letter topic with an owned replay or inspection process. For the given case, the controlling rationale is that choosing processing services must consider operational ownership and managed streaming capabilities as well as language preference.
Question 400
The team is considering: Monitor subscription backlog, system lag and output freshness with actionable Cloud Monitoring alerts. The context is: A streaming Dataflow job stays running but its Pub/Sub input backlog grows and published data becomes stale. Which engineering principle is MOST relevant?
- A job's RUNNING state does not guarantee the pipeline is keeping up with its data source.
- Permission failures require identifying the denied principal and resource rather than treating the problem as transient availability.
- Pipeline observability must expose data-quality losses as well as infrastructure job status.
- Quota failures must be distinguished from application exceptions and permission errors for correct remediation.
Explanation
Correct Answer
A:The governing principle is that a job's RUNNING state does not guarantee the pipeline is keeping up with its data source. It explains why the team should monitor subscription backlog, system lag and output freshness with actionable Cloud Monitoring alerts. The current problem is: A streaming Dataflow job stays running but its Pub/Sub input backlog grows and published data becomes stale. Without the safeguard, business reports can lag for hours without a failed worker or visible red job status. A suitable proof is: An injected sustained backlog crosses the lag threshold and pages the named owner.
Incorrect Answers
B:That principle applies primarily to a different design condition: A warehouse export returns HTTP 403 and an engineer repeatedly restarts it without checking source and sink identities. There the relevant engineering response is to inspect the relevant Cloud Audit Logs, job error details and effective IAM permissions for each resource. For the given case, the controlling rationale is that a job's RUNNING state does not guarantee the pipeline is keeping up with its data source.
C:That principle applies primarily to a different design condition: An Apache Beam transformation silently drops invalid records but the dashboard shows only total successful records. There the relevant engineering response is to instrument per-stage accepted, rejected and dead-letter counters with source-volume reconciliation. For the given case, the controlling rationale is that a job's RUNNING state does not guarantee the pipeline is keeping up with its data source.
D:That principle applies primarily to a different design condition: A scheduled Dataflow job begins failing with resource-exhausted responses after a source volume increase. There the relevant engineering response is to correlate quotas, worker logs and API error details with cloud service usage metrics before escalation. For the given case, the controlling rationale is that a job's RUNNING state does not guarantee the pipeline is keeping up with its data source.