Skip to content

ExternalTaskSensorTrigger ignores poke_interval and polls every 2 seconds with excessive logging while using deferrable=True #68990

Description

@surendarvarmas

Description

Type: Bug / Feature Request

Apache Airflow version: 2.10.3

What happened:

When using ExternalTaskSensor with deferrable=True, the poke_interval parameter is ignored. The trigger polls every ~2 seconds regardless of the configured poke_interval, and logs "Sleeping for 2.0 seconds" on every cycle.

For a sensor with a 6-hour timeout, this generates ~10,800 log lines per task instance.

Use case/motivation

The trigger should respect the poke_interval parameter (or provide a separate trigger_poll_interval parameter) to control how often it checks the external DAG state, similar to how the non-deferred reschedule mode respects poke_interval.

Additional context:

This makes deferrable=True impractical for ExternalTaskSensor compared to mode="reschedule", which properly respects poke_interval and produces cleaner, more useful logs (including the external DAG name being waited on).

Related issues

No response

Are you willing to submit a PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions