Allow pausing an asset watcher without pausing its Dags
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.
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
/assign-me
Feel free to take it on!
Thanks @seanghaeli! Starting work on this now. /assign-me