Which TWO of the following are valid ways to trigger a Cloud Composer DAG?
The 'Trigger DAG' button is a primary method.
Why this answer
DAGs can be triggered by a timer (schedule) or manually through the Airflow Web UI/CLI.
205 questions total · 3pages · All types, answers revealed
Which TWO of the following are valid ways to trigger a Cloud Composer DAG?
The 'Trigger DAG' button is a primary method.
Why this answer
DAGs can be triggered by a timer (schedule) or manually through the Airflow Web UI/CLI.
Which console menu would you navigate to in order to access Dataplex?
Dataplex is grouped under Analytics services.
Why this answer
Dataplex is found under the 'Analytics' section in the Google Cloud console.
Your organization requires that all data ingested into Cloud Storage be encrypted at rest using keys managed by you, not Google. Which feature should you implement?
CMEK allows users to use Cloud KMS to manage keys for their data in Cloud Storage.
Why this answer
Customer-Managed Encryption Keys (CMEK) via Cloud KMS allow you to control the encryption keys used for your data.
Which TWO of the following are benefits of using Cloud Storage?
Data is accessible from anywhere.
Why this answer
GCS offers high durability and global accessibility.
You are using BigQuery and need to query a large dataset that is partitioned by day. Which clause should you always include for efficiency?
This filters the partition and saves on costs.
Why this answer
Including a filter on the partition column (e.g., _PARTITIONDATE or a specific date column) avoids full table scans.
Which Cloud Composer metric should you monitor to identify if your Airflow scheduler is struggling to parse your DAGs in a timely manner?
This metric tracks DAG parsing performance.
Why this answer
The 'dag_processing_total_parse_time' metric specifically tracks the time taken to process and parse DAG files.
You are deploying a Cloud Composer 2 environment and need to ensure that the DAG files are automatically synchronized to all workers. Where should you store these files?
The bucket associated with the environment is the designated location for DAG files.
Why this answer
Cloud Composer 2 automatically synchronizes DAGs stored in the 'dags/' folder of the associated Cloud Storage bucket to all environment components.
Which TWO actions can help reduce the time it takes to build a Jupyter notebook in Vertex AI Workbench?
Larger machines can handle more compute tasks faster.
Why this answer
Optimizing compute and pre-installing environments can speed up development.
In BigQuery, what does the 'Data Preview' tab show?
Previewing data is free and provides a quick look at the content.
Why this answer
The preview shows a sample of the rows in the table without consuming query quota or incurring costs.
Which THREE of the following are valid Airflow connection types in Cloud Composer?
Used for API calls.
Why this answer
Airflow supports connections to many systems, including Google Cloud, HTTP, and SQL databases.
In BigQuery, you want to improve query performance for a table that is frequently filtered by a `customer_id` column. What is the recommended strategy?
Clustering improves performance for filtering and grouping queries on the cluster key.
Why this answer
Clustering by `customer_id` organizes the data physically to optimize queries that filter by that specific column.
A Cloud Composer DAG is failing because the Airflow database is locking up during high-concurrency periods. What is the most effective way to address this?
Composer environment sizes (e.g., small to medium) include higher-tier database resources.
Why this answer
Scaling the Composer environment or adjusting the database performance settings (or Airflow configuration) is the recommended path to resolve lock contention.
You have multiple departments using the same Dataplex Lake. You need to ensure that each department can only see data belonging to their own projects. What should you configure?
Zones allow for scoping data and security boundaries within a single lake.
Why this answer
Dataplex Zones allow for logical separation within a Lake, where permissions can be scoped to the zone level.
You are troubleshooting a stuck task in Cloud Composer. You want to see the stdout/stderr logs for that specific task attempt. Where can you find them?
Composer writes all task execution logs to the GCS bucket.
Why this answer
Airflow task logs are stored in the GCS bucket associated with the environment, organized by DAG and task name.
You have a Workflow that must wait for a specific time duration before proceeding. Which step type is most appropriate?
sys.sleep pauses the workflow execution for a set time.
Why this answer
The 'sys.sleep' function in Workflows allows pausing the execution for a defined duration.
You are running a Dataflow job that joins two large datasets. Which join strategy should you avoid to prevent OOM errors?
Side inputs are loaded into memory and should not be used for very large datasets.
Why this answer
Broadcasting a large dataset to all workers (Side Inputs) can lead to Out of Memory (OOM) errors.
Which TWO of the following are valid ways to monitor Dataflow performance?
Shows job metrics.
Why this answer
Monitoring UI and Cloud Logging are the primary tools.
You need to ingest small files into Cloud Storage using a command-line tool. Which command is most appropriate?
This is also correct as gcloud storage is the modern gsutil.
Why this answer
gsutil cp is the standard command for copying files to GCS.
Which TWO of the following are valid ways to ingest data into BigQuery?
Method for real-time ingestion.
Why this answer
BigQuery supports Batch Load jobs and Streaming API inserts.
You need to move an asset from one Dataplex Zone to another. What is the correct procedure?
Assets are zone-bound; deletion and recreation is the required path.
Why this answer
Assets are tied to a specific zone. To move an asset, you must remove it from the source zone and add it to the destination zone.
You need to delete all files in a GCS bucket older than 90 days. What is the most efficient approach?
Lifecycle policies handle this automatically at the storage level.
Why this answer
GCS Lifecycle policies can automatically delete or move objects based on age.
You are optimizing a Dataflow job. Which THREE of the following actions can help improve job performance and reduce costs?
Autoscaling ensures resources are added only when needed.
Why this answer
Autoscaling, proper shuffle service usage, and resource tuning are essential for cost and performance.
Which property in a Workflows YAML definition is required to define the entry point of the workflow?
Every workflow must have a 'main' block.
Why this answer
The 'main' step is the required starting point for any workflow execution.
You need to track who accessed which GCS bucket. Which service provides this audit trail?
Audit logs track all API calls to GCS.
Why this answer
Cloud Audit Logs, when enabled, capture all access events for GCS buckets.
What does 'Data Lineage' show you in Dataplex?
Lineage captures the 'where did this come from' information.
Why this answer
Data lineage tracks the origin, movement, and transformations of data as it moves through the pipeline.
Which component of Cloud Composer acts as the primary interface for managing and triggering DAGs manually?
The web UI provides the DAG management dashboard.
Why this answer
The Airflow Web Interface is the primary UI for managing DAGs and viewing execution history.
Which TWO of the following are key benefits of using Dataflow?
No infrastructure to manage.
Why this answer
Dataflow is fully managed and supports both batch and streaming.
You are processing streaming data in Pub/Sub and need to archive every message into GCS without writing custom code. What should you use?
This is a native feature that avoids writing code.
Why this answer
Pub/Sub's native Cloud Storage subscription allows for direct streaming of messages to files in GCS.
In a Cloud Composer DAG, you need to trigger a BigQuery job that runs as a service account other than the one assigned to the GKE nodes. How should you implement this?
This is the secure way to perform service account impersonation in Airflow operators.
Why this answer
Using the 'impersonation_chain' parameter in the BigQueryInsertJobOperator allows the service account running the task to impersonate a different service account.
Your organization uses Workflows to orchestrate multi-step API calls. You need to handle transient failures in a specific HTTP request by retrying it up to 5 times with exponential backoff. Which block should you use?
The retry block handles exceptions and allows defining custom parameters like max_retries and backoff.
Why this answer
The 'try/retry' block in Workflows syntax allows for configuring custom backoff and max attempts for specific steps.
Which TWO are common causes of Dataflow pipeline failures?
Causes processing errors.
Why this answer
Bad input data and configuration errors are common failures.
You need to migrate legacy data to a Dataplex Lake. Which THREE of the following should you consider for a successful migration? (Choose three)
Plan your organization structure.
Why this answer
Migration requires planning for IAM, discovery, and testing.
You are configuring a Dataplex asset that points to a GCS bucket. You want to ensure that only files in a specific folder are included in the asset. How do you specify this?
Dataplex assets support prefix filters for GCS buckets.
Why this answer
When adding a GCS bucket as an asset, you can provide a filter or prefix to limit the scope to a specific path.
You have an automated pipeline that deletes files in a GCS bucket every hour. Dataplex shows the asset as 'Out of sync'. Why?
Metadata becomes stale if discovery hasn't refreshed the state.
Why this answer
Dataplex discovery scans periodically; if the physical data changes without the discovery job having run, the metadata might show as out of sync.
Which TWO types of data sources can be used to create a dashboard in Looker Studio?
Native Google Cloud integration.
Why this answer
Looker Studio supports many connectors including BigQuery and flat files.
You need to set up an alert when a GCS bucket exceeds a certain size. Which tool do you use?
Cloud Monitoring provides thresholds and alert policies for GCS.
Why this answer
Cloud Monitoring allows you to set up alerts based on GCS bucket metrics like byte count.
You need to audit who accessed sensitive data in a Dataplex Lake. Which service should you monitor to see access logs for these data assets?
Audit logs capture all API requests and access to Google Cloud resources.
Why this answer
Cloud Audit Logs records all access to data assets; Dataplex provides a unified view, but the logs reside in Cloud Audit Logs.
You are processing streaming data in Dataflow and notice 'stuck' elements causing pipeline latency. Which feature helps debug this?
The monitoring UI provides insight into pipeline status and work item processing.
Why this answer
Dataflow's Streaming Engine and Work Items UI allow you to inspect pipeline performance and identify bottlenecks.
You want to share a BigQuery dataset with a partner who uses a different Google Cloud project. What is the most secure way to grant them access?
This is the least privilege, most secure way to share access.
Why this answer
Using IAM to grant 'BigQuery Data Viewer' on that specific dataset is the standard way to provide secure access.
You need to perform a time-series analysis in BigQuery. Your data contains timestamps at a millisecond level, but you need to aggregate by hour. What is the most performant way to truncate the timestamp?
This function is the standard and most performant way to truncate timestamps.
Why this answer
The TIMESTAMP_TRUNC function is highly optimized for this specific task in BigQuery.
You are using Dataflow to read from Pub/Sub. The pipeline is failing due to malformed messages. How can you handle these without crashing?
DLQ allows you to isolate and examine malformed messages.
Why this answer
Using a Dead Letter Queue (DLQ) pattern allows you to route unprocessable messages to a separate destination for inspection.
You are configuring a Cloud Data Fusion pipeline to ingest data from an external SQL database. You need to ensure that only rows modified within the last hour are ingested. Which feature should you use?
CDC captures modifications effectively for delta ingestion.
Why this answer
Incremental ingestion using a watermark or high-watermark column is standard for loading only changed data.
Which TWO of the following SQL techniques in BigQuery are best for optimizing performance on large tables?
Pruning data is the most effective way to reduce cost and runtime.
Why this answer
Filtering and selecting specific columns are the two most important query optimization techniques.
Which TWO are valid methods to trigger a Dataflow job?
Manual trigger.
Why this answer
Cloud Scheduler and manual console submission are common triggers.
You have a large CSV file in Cloud Storage that needs to be loaded into BigQuery. The file contains a nested JSON structure in one column. How should you best prepare this data?
BigQuery can infer schema and handle nested JSON if the format is correct.
Why this answer
Using BigQuery's native JSON support or Dataflow allows parsing nested structures during the load process.
You are cleaning data using Dataprep. You want to save the final dataset in BigQuery. What do you do?
Exporting allows you to specify a BigQuery table as the target.
Why this answer
In Dataprep, you configure a publishing action to write the results to a BigQuery table.
You want to automate the export of a BigQuery table to Cloud Storage on a daily basis. What should you use?
This service supports scheduled jobs for moving data.
Why this answer
BigQuery Data Transfer Service allows for scheduled exports and imports.
You want to run a Dataflow pipeline on a schedule. What should you use?
Cloud Scheduler is the standard way to schedule recurring tasks.
Why this answer
Cloud Scheduler can trigger Dataflow template jobs on a predefined schedule.
You are troubleshooting a Dataflow job that is running slower than expected when writing data to BigQuery. You suspect the issue is related to hot keys. What is the recommended strategy to mitigate this?
Adding a random salt distributes the data more evenly across the processing workers.
Why this answer
Keyed distribution issues can be solved by adding a random salt to keys to ensure better distribution across workers.
You want to dynamically generate tasks in an Airflow DAG based on the number of files in a GCS bucket. What is the standard way to do this?
Dynamic task generation is achieved by looping in the DAG module.
Why this answer
Use a Python loop within the DAG file to iterate over the list of files (often using the GCS hook) and create Task instances dynamically.
Which THREE of the following are common steps in a typical data pipeline orchestration pattern?
Ensuring data quality.
Why this answer
Common steps include data ingestion, transformation, and validation/export.
You need to perform a rolling update on a Dataflow job without losing current state. How do you do this?
This updates the pipeline code while trying to preserve state.
Why this answer
Using the 'Update' feature with a job ID allows you to update the pipeline code while maintaining state (if possible).
Which GCS storage class is most cost-effective for data accessed only once per year?
Archive is the cheapest for very infrequent access.
Why this answer
Archive storage is designed for data that is rarely accessed (once a year or less).
You are using Dataflow with a custom container. Which command do you use to specify the container image?
This flag correctly sets the custom container.
Why this answer
The --sdk_container_image flag in the Dataflow runner specifies the image.
When designing a Looker dashboard, you need to display a value that is the average of a specific metric across the entire dashboard. What is the best method?
Single value tiles are perfect for highlighting KPIs and averages.
Why this answer
Single Value visualizations in Looker allow for displaying an aggregated metric clearly.
Which Dataplex component allows you to query data across different storage systems using a single SQL interface?
BigQuery acts as the compute engine for querying data assets in the lake.
Why this answer
The Dataplex Lake provides a unified view, and BigQuery Omni or federated queries allow querying across different storage systems.
You are configuring a Dataplex Data Quality task. You want to validate that a 'user_id' column has no NULL values. Where do you define this rule?
Dataplex expects a YAML file defining the quality rules to be passed to the task.
Why this answer
Data quality rules are defined in a YAML configuration file that Dataplex uses to run the quality check task.
Your team wants to visualize BigQuery data in Looker Studio. What is the most efficient way to ensure the dashboard reflects fresh data without manual refreshes?
Direct Query sends every request to BigQuery, ensuring data is as fresh as the underlying table.
Why this answer
Looker Studio supports query caching settings, but for live data, using the 'Direct Query' connection method is best.
You are developing a dashboard in Looker. You notice that the 'Explore' menu is missing a specific set of fields. What should you check in the LookML model?
If fields are not exposed in the Explore definition, they cannot be used.
Why this answer
If fields are defined but not included in the Explore via the 'fields' parameter or 'join' syntax, they will not be visible.
You need to ingest large amounts of unstructured data into Cloud Storage from an on-premises data center with limited bandwidth. Which service should you choose to ensure the most cost-effective and secure transfer?
Storage Transfer Service is the managed service for transferring data from on-premises to Cloud Storage.
Why this answer
Storage Transfer Service is designed for large-scale data migration from on-premises sources to Cloud Storage.
You are identifying trends in a large dataset using BigQuery. Which SQL function is best suited to identify the top 5 products sold per region?
This partitions the data by region and ranks sales, making it easy to filter for the top 5.
Why this answer
Window functions, specifically RANK() or DENSE_RANK() combined with PARTITION BY, are designed for this exact use case.
Which THREE factors should you consider when choosing a partitioning strategy for a BigQuery table?
Query patterns should dictate partition design.
Why this answer
Partitioning should be based on common filters, data size, and the query lifecycle.
Which TWO of the following are valid locations for a Dataplex Lake? (Choose two)
A valid multi-regional location.
Why this answer
Dataplex supports regional and multi-regional deployments.
What is the benefit of using 'Scheduled Reports' in Looker?
This is a key feature for operationalizing insights.
Why this answer
Scheduled reports automatically deliver data to users via email, ensuring stakeholders get insights without logging in.
Which THREE of the following are valid GCS storage classes?
Valid class.
Why this answer
Standard, Nearline, and Coldline are valid GCS storage classes.
A user is running a query on a BigQuery table with nested data (JSON). How do you access a field named 'city' inside a record field named 'address'?
The dot operator is used for accessing nested fields.
Why this answer
Standard SQL uses the dot notation (dot-walk) to access fields within a STRUCT.
A marketing manager needs to see daily sales trends in Looker. The underlying data is in BigQuery and is updated every 6 hours. What is the best way to visualize this?
Explores allow for dynamic, accurate time-series visualization.
Why this answer
Creating a Looker Explore enables the manager to create visualizations dynamically while ensuring they always see the latest data from BigQuery.
Which service allows you to view the schema and metadata of a BigQuery table that has been registered in Dataplex?
Data Catalog is the tool used for viewing schema and metadata.
Why this answer
The Data Catalog interface within Dataplex provides a unified view of metadata, including schemas.
What is the purpose of a 'Data Zone' in Dataplex?
Zones serve as the logical boundary for policies and data management.
Why this answer
Zones are used to group data assets within a lake for common governance, security, and lifecycle policies.
Your team uses Dataprep by Trifacta to clean data before loading it into BigQuery. You notice that the column header names contain inconsistent casing and special characters. Which Dataprep transformation should you use to standardize these headers globally?
Rename allows for targeted adjustments to header names to ensure consistency.
Why this answer
The 'Rename' or 'Header' transformation allows for bulk column modification, but 'Rename' with regex or individual mapping is standard for header cleanup.
You are using Vertex AI Workbench and want to ensure your notebook environment persists after the instance is stopped. Where should you save your work?
Persistent disks retain data even when the VM is stopped.
Why this answer
Notebook instances are compute resources; the persistent disk attached to the instance or an external Cloud Storage bucket is required to keep data.
You are building a Looker dashboard and need to calculate the year-over-year growth rate. Which feature should you use to perform this without modifying the underlying SQL?
Table calculations provide flexible, on-the-fly math capabilities.
Why this answer
Table calculations allow for creating new measures based on existing data in the Explore interface without affecting the underlying database model.
You have sensitive data in Cloud Storage that needs to be deleted after 30 days to comply with regulatory requirements. What is the most efficient way to manage this?
Lifecycle rules are the native and most efficient way to handle object expiration.
Why this answer
Object lifecycle management rules in Cloud Storage are the standard way to automate data deletion based on age.
Which TWO of the following are common reasons a Workflows execution might stay in a 'PENDING' or 'FAILED' state?
Syntax errors prevent successful deployment/execution.
Why this answer
Common issues include invalid IAM permissions or malformed YAML syntax in the workflow definition.
Which command-line tool do you primarily use to deploy and manage Workflows?
gcloud workflows is the CLI command set for this service.
Why this answer
The 'gcloud' CLI is the standard tool for managing Google Cloud services, including Workflows.
Practice GCP-ADP by domain
Target a specific domain to shore up weak areas.