Introduction à Apache Airflow en Python
Mike Metzger
Data Engineer
Pour exécuter une tâche précise en ligne de commande :
airflow tasks test <dag_id> <task_id> <date>
Pour exécuter un Dag complet :
airflow dags trigger --logical-date <date> <dag_id>
@task - Définit une fonction Python comme tâche Airflow@task.bash - Retourne le résultat d’une commande bash comme sortie de tâche@task.branch - Opérateur de branchement pour choisir à l’exécution dans un DagFileSensor - requiert l’argument filepath et peut utiliser mode ou poke_intervalfrom airflow.sdk import dag, task)help(<objet Airflow>), p. ex., help(task)



Introduction à Apache Airflow en Python