airflow icon indicating copy to clipboard operation
airflow copied to clipboard

Allow pausing an asset watcher without pausing its Dags

Open seanghaeli opened this issue 2 weeks ago • 4 comments

Today the only way to stop an asset watcher is to pause every Dag scheduled on its asset or remove it from the Dag. Both delete its trigger (add_asset_trigger_references in airflow-core/src/airflow/dag_processing/collection.py), so its failure history goes too (#77054), and pausing the Dags also stops any other assets or schedules they use. When a watcher keeps failing because the system it watches is down, it would help to pause just that watcher until it's fixed, and resume it later with its history intact.

Suggestion: a pause flag on the asset watcher, set through the API and UI. The triggerer doesn't run a paused watcher's trigger, and cleanup doesn't delete it. Watchers on one shared trigger need a rule: the trigger keeps running while any of its watchers isn't paused. With #76567, the Triggers page is a natural place for the pause button.

Done when: a watcher can be paused and resumed through the API (and UI), a paused watcher's trigger isn't run or deleted, and its failure history is still there after it resumes, with tests.

seanghaeli avatar Nov 13 '26 18:11 seanghaeli

Hi! I'd like to work on this issue. I noticed that #76567 (which adds the Triggers UI page) is currently open in review.

Are you planning to implement this after #76567 lands, or would you be open to me picking this up (e.g. starting on the backend/API pause flag changes first)?


Drafted-by: Antigravity; reviewed by @RyukR1 before posting

RyukR1 avatar Nov 15 '26 15:11 RyukR1

/assign-me

AnishKmSingh avatar Nov 18 '26 12:11 AnishKmSingh

Feel free to take it on!

seanghaeli avatar Nov 21 '26 07:11 seanghaeli

Thanks @seanghaeli! Starting work on this now. /assign-me

RyukR1 avatar Nov 21 '26 15:11 RyukR1