metadata-ingestion-modules/airflow-plugin/src/datahub_airflow_plugin/example_dags/README.md
Example DAGs demonstrating various features of the DataHub Airflow plugin. All examples target Airflow 3.1+.
Examples showing how to automatically collect lineage from your Airflow DAGs:
inlets and outlets@task decorator)Examples showing how to ingest metadata from data sources into DataHub:
DatahubEmitterOperatorDataHubGraph client from within a DAGCopy the example to your Airflow DAGs folder:
cp lineage_backend_demo.py $AIRFLOW_HOME/dags/
Configure the DataHub connection in Airflow:
airflow connections add datahub_rest_default \
--conn-type datahub-rest \
--conn-host http://localhost:8080
Enable the DAG in the Airflow UI or trigger it manually:
airflow dags trigger datahub_lineage_backend_demo