professional-cloud-data-engineer
Prepare and test your skills
Prepare and test your skills
Worked example. The correct answer is already marked and every option is explained below, so there is nothing to select here. To answer questions yourself, start the free trial.
Keep the momentum going with these hand-picked practice scenarios
Want more questions like this?
Get a free certification question every week.
Last updated
An enterprise data platform receives real-time transaction events via Pub/Sub and writes them directly into BigQuery using a BigQuery subscription with use_topic_schema enabled. To implement strict data contract governance across upstream producers and analytical downstream tables, the engineering team must satisfy the following architectural requirements:
Which architectural configuration should the team implement?
Attach an Apache Avro or Protocol Buffer schema to the Pub/Sub topic, and configure a dead-letter topic on the BigQuery subscription to capture failed messages with the CloudPubSubDeadLetterSourceDeliveryErrorMessage attribute.
Define a Data Catalog tag template on the BigQuery table to enforce data types, enable schema auto-detection on the subscription, and capture failed rows via BigQuery session query labels.
Attach a JSON Schema definition to the Pub/Sub subscription and configure BigQuery column-level encryption using AEAD functions to automatically reject malformed data into Cloud KMS audit logs.
Configure the BigQuery subscription with use_table_schema enabled and rely on BigQuery time travel and table snapshots to restore and analyze corrupted data elements after ingestion.
Attach an Apache Avro or Protocol Buffer schema to the Pub/Sub topic, and configure a dead-letter topic on the BigQuery subscription to capture failed messages with the CloudPubSubDeadLetterSourceDeliveryErrorMessage attribute.
This solution establishes an end-to-end data contract by binding an Apache Avro or Protocol Buffer schema directly to a Pub/Sub topic, enforcing structural validation at the ingestion boundary while leveraging native BigQuery subscription schema compatibility and dead-letter topics for deterministic failure handling.
use_topic_schema is set on a BigQuery subscription, Pub/Sub checks compatibility with the BigQuery table schema. String fields mapped to TIMESTAMP, DATETIME, DATE, TIME, NUMERIC, or BIGNUMERIC columns must adhere strictly to BigQuery formatting rules; otherwise, BigQuery refuses the row.CloudPubSubDeadLetterSourceDeliveryErrorMessage attribute, providing the exact reason the message failed to load into BigQuery.This architecture enforces contract boundaries natively across serverless Google Cloud services without provisioning intermediate compute clusters, ensuring strict schema governance and automated dead-letter forensics.
Define a Data Catalog tag template on the BigQuery table to enforce data types, enable schema auto-detection on the subscription, and capture failed rows via BigQuery session query labels.
Attach a JSON Schema definition to the Pub/Sub subscription and configure BigQuery column-level encryption using AEAD functions to automatically reject malformed data into Cloud KMS audit logs.
Configure the BigQuery subscription with use_table_schema enabled and rely on BigQuery time travel and table snapshots to restore and analyze corrupted data elements after ingestion.