Einführung in Apache Airflow mit Python
Mike Metzger
Data Engineer

from airflow.providers.standard.operators.hitl import ApprovalOperatorsubject – Betreff/Titel der Genehmigungbody – Inhalt der Nachrichtexecution_timeout – timedelta, wie lange auf Antwort gewartet wirddefaults – Standard: bei Timeout approve oder rejectassigned_users – Liste von Nutzern, an die gepostet wirdapprove_gate = ApprovalOperator(
task_id="approve_data_import",
subject="Data import - Approval Required",
body=(
"Please review the data produced by the *extract_info* task."
"Approve to write data to the database, or Reject to halt the run."
),
)
In der Dag-Run-Ansicht erscheint „RequiredActions“, wenn eine Genehmigung aussteht.



Einführung in Apache Airflow mit Python