Skip to content

Building a DAG for Cloud Composer

Cloud Composer is Google Cloud's managed Apache Airflow service, and DAGs are Python files that define workflows as tasks with dependencies, which you upload to Composer's environment to schedule and orchestrate data pipelines. Understanding DAG authoring, scheduling, and GCS-based deployment is essential for automating ETL/ELT workloads on Google Cloud.

Must-know

  • DAGs are deployed by uploading Python files to the /dags folder in the Cloud Composer environment's associated Cloud Storage bucket, and Airflow automatically picks them up.
  • Composer provides Google Cloud-specific operators and hooks (e.g., for BigQuery, Dataproc, Dataflow, GCS, Pub/Sub) via the apache-airflow-providers-google package, reducing the need for custom code to interact with GCP services.
  • Task dependencies are set using bitshift operators (>> and <<) or set_upstream/set_downstream methods, and DAG structure determines execution order, retries, and parallelism.
  • Use Airflow Variables and Connections (stored encrypted in the environment's metadata database) to parameterize DAGs instead of hardcoding credentials or environment-specific values, and prefer Secret Manager backend integration for sensitive data.
  • The schedule_interval (or newer schedule parameter) combined with the DAG's start_date and catchup setting determines whether past runs are backfilled; setting catchup=False avoids unintended historical DAG runs.
  • Sensors (e.g., for GCS object existence or BigQuery job completion) and deferrable operators help avoid worker slot exhaustion by waiting efficiently for external conditions before triggering downstream tasks.

Coverage checked against the published exam guide on Aug 11, 2026.

These are independent practice questions, written against this certification's published exam guide. They are not the certification vendor's own questions, and not the real exam.