Airflow 在给定的结束日期之前,dag不会运行

Airflow 在给定的结束日期之前,dag不会运行,airflow,directed-acyclic-graphs,airflow-scheduler,Airflow,Directed Acyclic Graphs,Airflow Scheduler,我有一个回填DAG,计划从2012年1月1日到2018年1月1日每年运行一次,但仅从2012年1月1日到2017年1月1日运行。为什么它要运行到2018年1月1日,以及如何使它运行到2018年 以下是我在DAG中使用的代码: default_args = { 'owner': 'airflow', 'depends_on_past': False, 'start_date': datetime(2012,1,1), 'end_date': datetime(201

我有一个回填DAG,计划从2012年1月1日到2018年1月1日每年运行一次,但仅从2012年1月1日到2017年1月1日运行。为什么它要运行到2018年1月1日,以及如何使它运行到2018年

以下是我在DAG中使用的代码:

default_args = {
    'owner': 'airflow',
    'depends_on_past': False,
    'start_date': datetime(2012,1,1),
    'end_date': datetime(2018,1,1),
    'email': ['sef12@gmail.com'],
    'email_on_failure': True,
    'email_on_retry': False,
    'retries': 1,
    'retry_delay': timedelta(seconds=5)
}

dag = DAG(
        dag_id='SAMPLE_LOAD',schedule_interval= '@yearly',default_args=default_args,catchup=True,max_active_runs=1, concurrency=1) 

这是由于气流处理调度的方式。从:

请注意,如果您以一天的时间间隔运行DAG,则在2016-01-01T23:59之后不久将触发标有2016-01-01的运行。换句话说,一旦作业实例所覆盖的时间段结束,它就会启动

让我们重复一下,调度程序在开始日期之后的一个调度时间间隔内,在周期结束时运行作业

2018年的跑步将在2018年结束后开始,因为这是间歇期的结束