airflow.providers.standard.sensors.time_delta
¶
Module Contents¶
Classes¶
Waits for a timedelta after the run's data interval. |
|
A deferrable drop-in replacement for TimeDeltaSensor. |
|
A sensor that waits a specified period of time before completing. |
- class airflow.providers.standard.sensors.time_delta.TimeDeltaSensor(*, delta, **kwargs)[source]¶
Bases:
airflow.sensors.base.BaseSensorOperator
Waits for a timedelta after the run’s data interval.
- Parameters
delta – time length to wait after the data interval before succeeding.
See also
For more information on how to use this sensor, take a look at the guide: TimeDeltaSensor
- class airflow.providers.standard.sensors.time_delta.TimeDeltaSensorAsync(*, end_from_trigger=False, delta, **kwargs)[source]¶
Bases:
TimeDeltaSensor
A deferrable drop-in replacement for TimeDeltaSensor.
Will defers itself to avoid taking up a worker slot while it is waiting.
- Parameters
delta – time length to wait after the data interval before succeeding.
end_from_trigger (bool) – End the task directly from the triggerer without going into the worker.
See also
For more information on how to use this sensor, take a look at the guide: TimeDeltaSensorAsync
- class airflow.providers.standard.sensors.time_delta.WaitSensor(time_to_wait, deferrable=conf.getboolean('operators', 'default_deferrable', fallback=False), **kwargs)[source]¶
Bases:
airflow.sensors.base.BaseSensorOperator
A sensor that waits a specified period of time before completing.
This differs from TimeDeltaSensor because the time to wait is measured from the start of the task, not the data_interval_end of the DAG run.
- Parameters
time_to_wait (datetime.timedelta | int) – time length to wait after the task starts before succeeding.
deferrable (bool) – Run sensor in deferrable mode