๐Ÿ”

PDE โ€” questions

Page 14 of 18 ยท 341 total questions.

Topic 1 ยท Question 262

You are on the data governance team and are implementing security requirements. You need to encrypt all your data in BigQuery by using an encryption key managed by your team. You must implement a mechanism to generate and store encryption material only on your on-premises hardware security module (HSM). You want to rely on Google managed solutions. What should you do?

  • ACreate the encryption key in the on-premises HSM, and import it into a Cloud Key Management Service (Cloud KMS) key. Associate the created Cloud KMS key while creating the BigQuery resources.
  • BCreate the encryption key in the on-premises HSM and link it to a Cloud External Key Manager (Cloud EKM) key. Associate the created Cloud KMS key while creating the BigQuery resources. (correct answer)
  • CCreate the encryption key in the on-premises HSM, and import it into Cloud Key Management Service (Cloud HSM) key. Associate the created Cloud HSM key while creating the BigQuery resources.
  • DCreate the encryption key in the on-premises HSM. Create BigQuery resources and encrypt data while ingesting them into BigQuery.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Create the encryption key in the on-premises HSM and link it to a Cloud External Key Manager (Cloud EKM) key. Associate the created Cloud KMS key while creating the BigQuery resources.

Explanation

BigQuery is a serverless, petabyte-scale data warehouse for fast SQL analytics with no infrastructure to manage. Cloud KMS manages encryption keys and integrates with Google Cloud services for encryption. Cloud External Key Manager lets you hold encryption keys outside Google Cloud.

Topic 1 ยท Question 263

You maintain ETL pipelines. You notice that a streaming pipeline running on Dataflow is taking a long time to process incoming data, which causes output delays. You also noticed that the pipeline graph was automatically optimized by Dataflow and merged into one step. You want to identify where the potential bottleneck is occurring. What should you do?

  • AInsert a Reshuffle operation after each processing step, and monitor the execution details in the Dataflow console. (correct answer)
  • BInsert output sinks after each key processing step, and observe the writing throughput of each block.
  • CLog debug information in each ParDo function, and analyze the logs at execution time.
  • DVerify that the Dataflow service accounts have appropriate permissions to write the processed data to the output sinks.
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: Insert a Reshuffle operation after each processing step, and monitor the execution details in the Dataflow console.

Explanation

Dataflow runs serverless Apache Beam pipelines for stream and batch data processing with autoscaling. This option meets the real-time / low-latency performance requirement.

Topic 1 ยท Question 264

You are running your BigQuery project in the on-demand billing model and are executing a change data capture (CDC) process that ingests data. The CDC process loads 1 GB of data every 10 minutes into a temporary table, and then performs a merge into a 10 TB target table. This process is very scan intensive and you want to explore options to enable a predictable cost model. You need to create a BigQuery reservation based on utilization information gathered from BigQuery Monitoring and apply the reservation to the CDC process. What should you do?

  • ACreate a BigQuery reservation for the dataset.
  • BCreate a BigQuery reservation for the job.
  • CCreate a BigQuery reservation for the service account running the job.
  • DCreate a BigQuery reservation for the project. (correct answer)
Reveal answer & explanation
Correct answer: D

The correct answer is D. Option D: Create a BigQuery reservation for the project.

Explanation

BigQuery is a serverless, petabyte-scale data warehouse for fast SQL analytics with no infrastructure to manage.

Topic 1 ยท Question 265

You are designing a fault-tolerant architecture to store data in a regional BigQuery dataset. You need to ensure that your application is able to recover from a corruption event in your tables that occurred within the past seven days. You want to adopt managed services with the lowest RPO and most cost-effective solution. What should you do?

  • AAccess historical data by using time travel in BigQuery. (correct answer)
  • BExport the data from BigQuery into a new table that excludes the corrupted data
  • CCreate a BigQuery table snapshot on a daily basis.
  • DMigrate your data to multi-region BigQuery buckets.
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: Access historical data by using time travel in BigQuery.

Explanation

BigQuery is a serverless, petabyte-scale data warehouse for fast SQL analytics with no infrastructure to manage. This option delivers the requirement at the lowest cost.

Topic 1 ยท Question 266

You are building a streaming Dataflow pipeline that ingests noise level data from hundreds of sensors placed near construction sites across a city. The sensors measure noise level every ten seconds, and send that data to the pipeline when levels reach above 70 dBA. You need to detect the average noise level from a sensor when data is received for a duration of more than 30 minutes, but the window ends when no data has been received for 15 minutes. What should you do?

  • AUse session windows with a 15-minute gap duration. (correct answer)
  • BUse session windows with a 30-minute gap duration.
  • CUse hopping windows with a 15-minute window, and a thirty-minute period.
  • DUse tumbling windows with a 15-minute window and a fifteen-minute .withAllowedLateness operator.
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: Use session windows with a 15-minute gap duration. This option meets the real-time / low-latency performance requirement.

Topic 1 ยท Question 267

You are creating a data model in BigQuery that will hold retail transaction data. Your two largest tables, sales_transaction_header and sales_transaction_line, have a tightly coupled immutable relationship. These tables are rarely modified after load and are frequently joined when queried. You need to model the sales_transaction_header and sales_transaction_line tables to improve the performance of data analytics queries. What should you do?

  • ACreate a sales_transaction table that holds the sales_transaction_header information as rows and the sales_transaction_line rows as nested and repeated fields. (correct answer)
  • BCreate a sales_transaction table that holds the sales_transaction_header and sales_transaction_line information as rows, duplicating the sales_transaction_header data for each line.
  • CCreate a sales_transaction table that stores the sales_transaction_header and sales_transaction_line data as a JSON data type.
  • DCreate separate sales_transaction_header and sales_transaction_line tables and, when querying, specify the sales_transaction_line first in the WHERE clause.
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: Create a sales_transaction table that holds the sales_transaction_header information as rows and the sales_transaction_line rows as nested and repeated fields.

Topic 1 ยท Question 268

You created a new version of a Dataflow streaming data ingestion pipeline that reads from Pub/Sub and writes to BigQuery. The previous version of the pipeline that runs in production uses a 5-minute window for processing. You need to deploy the new version of the pipeline without losing any data, creating inconsistencies, or increasing the processing latency by more than 10 minutes. What should you do?

  • AUpdate the old pipeline with the new pipeline code.
  • BSnapshot the old pipeline, stop the old pipeline, and then start the new pipeline from the snapshot.
  • CDrain the old pipeline, then start the new pipeline. (correct answer)
  • DCancel the old pipeline, then start the new pipeline.
Reveal answer & explanation
Correct answer: C

The correct answer is C. Option C: Drain the old pipeline, then start the new pipeline. This option meets the real-time / low-latency performance requirement.

Topic 1 ยท Question 269

Your organization's data assets are stored in BigQuery, Pub/Sub, and a PostgreSQL instance running on Compute Engine. Because there are multiple domains and diverse teams using the data, teams in your organization are unable to discover existing data assets. You need to design a solution to improve data discoverability while keeping development and configuration efforts to a minimum. What should you do?

  • AUse Data Catalog to automatically catalog BigQuery datasets. Use Data Catalog APIs to manually catalog Pub/Sub topics and PostgreSQL tables.
  • BUse Data Catalog to automatically catalog BigQuery datasets and Pub/Sub topics. Use Data Catalog APIs to manually catalog PostgreSQL tables. (correct answer)
  • CUse Data Catalog to automatically catalog BigQuery datasets and Pub/Sub topics. Use custom connectors to manually catalog PostgreSQL tables.
  • DUse customer connectors to manually catalog BigQuery datasets, Pub/Sub topics, and PostgreSQL tables.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Use Data Catalog to automatically catalog BigQuery datasets and Pub/Sub topics. Use Data Catalog APIs to manually catalog PostgreSQL tables.

Explanation

BigQuery is a serverless, petabyte-scale data warehouse for fast SQL analytics with no infrastructure to manage. Pub/Sub is a serverless, global messaging service that decouples services and ingests high-volume event streams. Data Catalog provides metadata management and discovery across data assets.

Topic 1 ยท Question 270

You need to create a SQL pipeline. The pipeline runs an aggregate SQL transformation on a BigQuery table every two hours and appends the result to another existing BigQuery table. You need to configure the pipeline to retry if errors occur. You want the pipeline to send an email notification after three consecutive failures. What should you do?

  • AUse the BigQueryUpsertTableOperator in Cloud Composer, set the retry parameter to three, and set the email_on_failure parameter to true.
  • BUse the BigQueryInsertJobOperator in Cloud Composer, set the retry parameter to three, and set the email_on_failure parameter to true.
  • CCreate a BigQuery scheduled query to run the SQL transformation with schedule options that repeats every two hours, and enable email notifications.
  • DCreate a BigQuery scheduled query to run the SQL transformation with schedule options that repeats every two hours, and enable notification to Pub/Sub topic. Use Pub/Sub and Cloud Functions to send an email after three failed executions. (correct answer)
Reveal answer & explanation
Correct answer: D

The correct answer is D. Option D: Create a BigQuery scheduled query to run the SQL transformation with schedule options that repeats every two hours, and enable notification to Pub/Sub topic. Use Pub/Sub and Cloud Functions to send an email after thre...

Explanation

Cloud Functions runs event-driven code without managing servers and scales automatically. BigQuery is a serverless, petabyte-scale data warehouse for fast SQL analytics with no infrastructure to manage. Pub/Sub is a serverless, global messaging service that decouples services and ingests high-volume event streams.

Topic 1 ยท Question 271

You are monitoring your organizationโ€™s data lake hosted on BigQuery. The ingestion pipelines read data from Pub/Sub and write the data into tables on BigQuery. After a new version of the ingestion pipelines is deployed, the daily stored data increased by 50%. The volumes of data in Pub/Sub remained the same and only some tables had their daily partition data size doubled. You need to investigate and fix the cause of the data increase. What should you do?

  • A1. Check for duplicate rows in the BigQuery tables that have the daily partition data size doubled.2. Schedule daily SQL jobs to deduplicate the affected tables.3. Share the deduplication script with the other operational teams to reuse if this occurs to other tables.
  • B1. Check for code errors in the deployed pipelines.2. Check for multiple writing to pipeline BigQuery sink.3. Check for errors in Cloud Logging during the day of the release of the new pipelines.4. If no errors, restore the BigQuery tables to their content before the last release by using time travel.
  • C1. Check for duplicate rows in the BigQuery tables that have the daily partition data size doubled.2. Check the BigQuery Audit logs to find job IDs.3. Use Cloud Monitoring to determine when the identified Dataflow jobs started and the pipeline code version.4. When more than one pipeline ingests data into a table, stop all versions except the latest one. (correct answer)
  • D1. Roll back the last deployment.2. Restore the BigQuery tables to their content before the last release by using time travel.3. Restart the Dataflow jobs and replay the messages by seeking the subscription to the timestamp of the release.
Reveal answer & explanation
Correct answer: C

The correct answer is C. Option C: 1. Check for duplicate rows in the BigQuery tables that have the daily partition data size doubled.2. Check the BigQuery Audit logs to find job IDs.3. Use Cloud Monitoring to determine when the identified Dataflow job...

Explanation

BigQuery is a serverless, petabyte-scale data warehouse for fast SQL analytics with no infrastructure to manage. Dataflow runs serverless Apache Beam pipelines for stream and batch data processing with autoscaling. Cloud Monitoring collects metrics, dashboards, and alerts to observe system health.

Topic 1 ยท Question 272

You have a BigQuery dataset named โ€œcustomersโ€. All tables will be tagged by using a Data Catalog tag template named โ€œgdprโ€. The template contains one mandatory field, โ€œhas_sensitive_dataโ€, with a boolean value. All employees must be able to do a simple search and find tables in the dataset that have either true or false in the โ€œhas_sensitive_dataโ€™ field. However, only the Human Resources (HR) group should be able to see the data inside the tables for which โ€œhas_sensitive dataโ€ is true. You give the all employees group the bigquery.metadataViewer and bigquery.connectionUser roles on the dataset. You want to minimize configuration overhead. What should you do next?

  • ACreate the โ€œgdprโ€ tag template with private visibility. Assign the bigquery.dataViewer role to the HR group on the tables that contain sensitive data.
  • BCreate the โ€œgdprโ€ tag template with private visibility. Assign the datacatalog.tagTemplateViewer role on this tag to the all employees group, and assign the bigquery.dataViewer role to the HR group on the tables that contain sensitive data.
  • CCreate the โ€œgdprโ€ tag template with public visibility. Assign the bigquery.dataViewer role to the HR group on the tables that contain sensitive data. (correct answer)
  • DCreate the โ€œgdprโ€ tag template with public visibility. Assign the datacatalog.tagTemplateViewer role on this tag to the all employees group, and assign the bigquery.dataViewer role to the HR group on the tables that contain sensitive data.
Reveal answer & explanation
Correct answer: C

The correct answer is C. Option C: Create the โ€œgdprโ€ tag template with public visibility. Assign the bigquery.dataViewer role to the HR group on the tables that contain sensitive data.

Explanation

BigQuery is a serverless, petabyte-scale data warehouse for fast SQL analytics with no infrastructure to manage.

Topic 1 ยท Question 273

You are creating the CI/CD cycle for the code of the directed acyclic graphs (DAGs) running in Cloud Composer. Your team has two Cloud Composer instances: one instance for development and another instance for production. Your team is using a Git repository to maintain and develop the code of the DAGs. You want to deploy the DAGs automatically to Cloud Composer when a certain tag is pushed to the Git repository. What should you do?

  • A1. Use Cloud Build to copy the code of the DAG to the Cloud Storage bucket of the development instance for DAG testing.2. If the tests pass, use Cloud Build to copy the code to the bucket of the production instance. (correct answer)
  • B1. Use Cloud Build to build a container with the code of the DAG and the KubernetesPodOperator to deploy the code to the Google Kubernetes Engine (GKE) cluster of the development instance for testing.2. If the tests pass, use the KubernetesPodOperator to deploy the container to the GKE cluster of the production instance.
  • C1. Use Cloud Build to build a container and the KubernetesPodOperator to deploy the code of the DAG to the Google Kubernetes Engine (GKE) cluster of the development instance for testing.2. If the tests pass, copy the code to the Cloud Storage bucket of the production instance.
  • D1. Use Cloud Build to copy the code of the DAG to the Cloud Storage bucket of the development instance for DAG testing.2. If the tests pass, use Cloud Build to build a container with the code of the DAG and the KubernetesPodOperator to deploy the container to the Google Kubernetes Engine (GKE) cluster of the production instance.
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: 1. Use Cloud Build to copy the code of the DAG to the Cloud Storage bucket of the development instance for DAG testing.2. If the tests pass, use Cloud Build to copy the code to the bucket of the production instance.

Explanation

Cloud Storage provides durable, scalable object storage that is fully managed. Cloud Build runs managed CI pipelines to build, test, and package code.

Topic 1 ยท Question 274

You have a BigQuery table that ingests data directly from a Pub/Sub subscription. The ingested data is encrypted with a Google-managed encryption key. You need to meet a new organization policy that requires you to use keys from a centralized Cloud Key Management Service (Cloud KMS) project to encrypt data at rest. What should you do?

  • AUse Cloud KMS encryption key with Dataflow to ingest the existing Pub/Sub subscription to the existing BigQuery table.
  • BCreate a new BigQuery table by using customer-managed encryption keys (CMEK), and migrate the data from the old BigQuery table. (correct answer)
  • CCreate a new Pub/Sub topic with CMEK and use the existing BigQuery table by using Google-managed encryption key.
  • DCreate a new BigQuery table and Pub/Sub topic by using customer-managed encryption keys (CMEK), and migrate the data from the old BigQuery table.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Create a new BigQuery table by using customer-managed encryption keys (CMEK), and migrate the data from the old BigQuery table.

Explanation

BigQuery is a serverless, petabyte-scale data warehouse for fast SQL analytics with no infrastructure to manage.

Topic 1 ยท Question 275

You created an analytics environment on Google Cloud so that your data scientist team can explore data without impacting the on-premises Apache Hadoop solution. The data in the on-premises Hadoop Distributed File System (HDFS) cluster is in Optimized Row Columnar (ORC) formatted files with multiple columns of Hive partitioning. The data scientist team needs to be able to explore the data in a similar way as they used the on-premises HDFS cluster with SQL on the Hive query engine. You need to choose the most cost-effective storage and processing solution. What should you do?

  • AImport the ORC files to Bigtable tables for the data scientist team.
  • BImport the ORC files to BigQuery tables for the data scientist team.
  • CCopy the ORC files on Cloud Storage, then deploy a Dataproc cluster for the data scientist team.
  • DCopy the ORC files on Cloud Storage, then create external BigQuery tables for the data scientist team. (correct answer)
Reveal answer & explanation
Correct answer: D

The correct answer is D. Option D: Copy the ORC files on Cloud Storage, then create external BigQuery tables for the data scientist team.

Explanation

Cloud Storage provides durable, scalable object storage that is fully managed. BigQuery is a serverless, petabyte-scale data warehouse for fast SQL analytics with no infrastructure to manage. This option delivers the requirement at the lowest cost.

Topic 1 ยท Question 276

You are designing a Dataflow pipeline for a batch processing job. You want to mitigate multiple zonal failures at job submission time. What should you do?

  • ASubmit duplicate pipelines in two different zones by using the --zone flag.
  • BSet the pipeline staging location as a regional Cloud Storage bucket.
  • CSpecify a worker region by using the --region flag. (correct answer)
  • DCreate an Eventarc trigger to resubmit the job in case of zonal failure when submitting the job.
Reveal answer & explanation
Correct answer: C

The correct answer is C. Option C: Specify a worker region by using the --region flag.

Topic 1 ยท Question 277

You are designing a real-time system for a ride hailing app that identifies areas with high demand for rides to effectively reroute available drivers to meet the demand. The system ingests data from multiple sources to Pub/Sub, processes the data, and stores the results for visualization and analysis in real-time dashboards. The data sources include driver location updates every 5 seconds and app-based booking events from riders. The data processing involves real-time aggregation of supply and demand data for the last 30 seconds, every 2 seconds, and storing the results in a low-latency system for visualization. What should you do?

  • AGroup the data by using a tumbling window in a Dataflow pipeline, and write the aggregated data to Memorystore.
  • BGroup the data by using a hopping window in a Dataflow pipeline, and write the aggregated data to Memorystore. (correct answer)
  • CGroup the data by using a session window in a Dataflow pipeline, and write the aggregated data to BigQuery.
  • DGroup the data by using a hopping window in a Dataflow pipeline, and write the aggregated data to BigQuery.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Group the data by using a hopping window in a Dataflow pipeline, and write the aggregated data to Memorystore.

Explanation

Memorystore provides managed in-memory Redis/Memcached caching to reduce latency and offload databases. Dataflow runs serverless Apache Beam pipelines for stream and batch data processing with autoscaling. This option meets the real-time / low-latency performance requirement.

Topic 1 ยท Question 278

Your car factory is pushing machine measurements as messages into a Pub/Sub topic in your Google Cloud project. A Dataflow streaming job, that you wrote with the Apache Beam SDK, reads these messages, sends acknowledgment to Pub/Sub, applies some custom business logic in a DoFn instance, and writes the result to BigQuery. You want to ensure that if your business logic fails on a message, the message will be sent to a Pub/Sub topic that you want to monitor for alerting purposes. What should you do?

  • AEnable retaining of acknowledged messages in your Pub/Sub pull subscription. Use Cloud Monitoring to monitor the subscription/num_retained_acked_messages metric on this subscription.
  • BUse an exception handling block in your Dataflowโ€™s DoFn code to push the messages that failed to be transformed through a side output and to a new Pub/Sub topic. Use Cloud Monitoring to monitor the topic/num_unacked_messages_by_region metric on this new topic. (correct answer)
  • CEnable dead lettering in your Pub/Sub pull subscription, and specify a new Pub/Sub topic as the dead letter topic. Use Cloud Monitoring to monitor the subscription/dead_letter_message_count metric on your pull subscription.
  • DCreate a snapshot of your Pub/Sub pull subscription. Use Cloud Monitoring to monitor the snapshot/num_messages metric on this snapshot.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Use an exception handling block in your Dataflowโ€™s DoFn code to push the messages that failed to be transformed through a side output and to a new Pub/Sub topic. Use Cloud Monitoring to monitor the topic/num_unacked_m...

Explanation

Dataflow runs serverless Apache Beam pipelines for stream and batch data processing with autoscaling. Pub/Sub is a serverless, global messaging service that decouples services and ingests high-volume event streams. Cloud Monitoring collects metrics, dashboards, and alerts to observe system health. This option meets the real-time / low-latency performance requirement.

Topic 1 ยท Question 279

You want to store your teamโ€™s shared tables in a single dataset to make data easily accessible to various analysts. You want to make this data readable but unmodifiable by analysts. At the same time, you want to provide the analysts with individual workspaces in the same project, where they can create and store tables for their own use, without the tables being accessible by other analysts. What should you do?

  • AGive analysts the BigQuery Data Viewer role at the project level. Create one other dataset, and give the analysts the BigQuery Data Editor role on that dataset.
  • BGive analysts the BigQuery Data Viewer role at the project level. Create a dataset for each analyst, and give each analyst the BigQuery Data Editor role at the project level.
  • CGive analysts the BigQuery Data Viewer role on the shared dataset. Create a dataset for each analyst, and give each analyst the BigQuery Data Editor role at the dataset level for their assigned dataset. (correct answer)
  • DGive analysts the BigQuery Data Viewer role on the shared dataset. Create one other dataset and give the analysts the BigQuery Data Editor role on that dataset.
Reveal answer & explanation
Correct answer: C

The correct answer is C. Option C: Give analysts the BigQuery Data Viewer role on the shared dataset. Create a dataset for each analyst, and give each analyst the BigQuery Data Editor role at the dataset level for their assigned dataset.

Explanation

BigQuery is a serverless, petabyte-scale data warehouse for fast SQL analytics with no infrastructure to manage.

Topic 1 ยท Question 280

You are running a streaming pipeline with Dataflow and are using hopping windows to group the data as the data arrives. You noticed that some data is arriving late but is not being marked as late data, which is resulting in inaccurate aggregations downstream. You need to find a solution that allows you to capture the late data in the appropriate window. What should you do?

  • AUse watermarks to define the expected data arrival window. Allow late data as it arrives. (correct answer)
  • BChange your windowing function to tumbling windows to avoid overlapping window periods.
  • CChange your windowing function to session windows to define your windows based on certain activity.
  • DExpand your hopping window so that the late data has more time to arrive within the grouping.
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: Use watermarks to define the expected data arrival window. Allow late data as it arrives. This option meets the real-time / low-latency performance requirement.

Topic 1 ยท Question 281

You work for a large ecommerce company. You store your customer's order data in Bigtable. You have a garbage collection policy set to delete the data after 30 days and the number of versions is set to 1. When the data analysts run a query to report total customer spending, the analysts sometimes see customer data that is older than 30 days. You need to ensure that the analysts do not see customer data older than 30 days while minimizing cost and overhead. What should you do?

  • ASet the expiring values of the column families to 29 days and keep the number of versions to 1.
  • BUse a timestamp range filter in the query to fetch the customer's data for a specific range. (correct answer)
  • CSchedule a job daily to scan the data in the table and delete data older than 30 days.
  • DSet the expiring values of the column families to 30 days and set the number of versions to 2.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Use a timestamp range filter in the query to fetch the customer's data for a specific range.

Showing questions 261โ€“280 of 341 ยท Page 14 of 18