mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-11-01 02:56:10 +00:00
Add owner and tags to Airflow DAGs (#9135)
This commit is contained in:
parent
2baf6873b6
commit
f3ad74f792
@ -259,6 +259,10 @@ def build_dag_configs(ingestion_pipeline: IngestionPipeline) -> dict:
|
|||||||
or False,
|
or False,
|
||||||
"catchup": ingestion_pipeline.airflowConfig.pipelineCatchup or False,
|
"catchup": ingestion_pipeline.airflowConfig.pipelineCatchup or False,
|
||||||
"schedule_interval": ingestion_pipeline.airflowConfig.scheduleInterval,
|
"schedule_interval": ingestion_pipeline.airflowConfig.scheduleInterval,
|
||||||
|
"tags": [
|
||||||
|
"OpenMetadata",
|
||||||
|
ingestion_pipeline.pipelineType.value,
|
||||||
|
],
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -297,6 +301,10 @@ def build_dag(
|
|||||||
retries=0,
|
retries=0,
|
||||||
# each DAG will call its own OpenMetadataWorkflowConfig
|
# each DAG will call its own OpenMetadataWorkflowConfig
|
||||||
on_failure_callback=partial(send_failed_status_callback, workflow_config),
|
on_failure_callback=partial(send_failed_status_callback, workflow_config),
|
||||||
|
# Add tag and ownership to easily identify DAGs generated by OM
|
||||||
|
owner=ingestion_pipeline.owner.name
|
||||||
|
if ingestion_pipeline.owner
|
||||||
|
else "openmetadata",
|
||||||
)
|
)
|
||||||
|
|
||||||
return dag
|
return dag
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user