Airflow returns "Backfill done" 没有 运行 任务

Airflow returns "Backfill done" without running tasks

我 运行正在使用 Airflow 并尝试迭代我们正在从命令行构建的某些任务。

当 运行使用 airflow 网络服务器时,一切都按预期工作。但是当我运行airflow backfill dag task '2017-08-12',气流returns:

[2017-08-15 02:52:55,639] {__init__.py:57} INFO - Using executor LocalExecutor
[2017-08-15 02:52:56,144] {models.py:168} INFO - Filling up the DagBag from /usr/local/airflow/dags
2017-08-15 02:52:59,055 - airflow.jobs.BackfillJob - INFO - Backfill done. Exiting

...实际上 运行 狗。

当使用 airflow testairflow run 时(即涉及 运行 任务而不是 dag 的命令),它按预期工作

我犯了一个基本错误吗?我可以从这里调试什么?

谢谢

您 运行 已经在该日期范围内创建了那些 DAG 了吗?您需要先 clear DAG,然后 backfill。根据 Maxime 在这里提到的内容:https://groups.google.com/forum/#!topic/airbnb_airflow/gMY-sc0QVh0

如果任务有 @monthly 时间表,那么如果您尝试 运行 它与 start_date 月中,它只会显示 Backfill done. Exiting.。如果一个任务有一个 '30 5 * * *' 的时间表,这也会阻止 backfill 从命令行

(已更新以反映更好的信息,并且 this discussion

两个可能的原因:

  • 通过 -e 选项指定的执行日期超出了 DAG 的 [start_date, end_date) 范围。
  • 即使执行日期在日期之间,请记住,如果您的 DAG 有 schedule_interval=None,那么它不会 backfill 迭代:它只会 运行单个日期(如果第一个被省略,则指定为 --start_date--end_date)。