treasure-data / digdag

Workload Automation System
https://www.digdag.io/
Apache License 2.0
1.3k stars 221 forks source link

[feature request] want a command to stop workflow schedules completely (not resumable) #995

Open sonots-zozo opened 5 years ago

sonots-zozo commented 5 years ago

We used digdag disable, and then digdag enable after a few days. We noticed that all jobs during being disabled were enqueued accidently. ref. https://qiita.com/shiozaki/items/d7ea6fe358da46bc13b5 (Japanese)

To avoid this accident, I prefer to

  1. have another command to disable schedule completely
  2. Or, have another command to purge enqueued jobs then enable

I feel that

(although I know this change breaks backward compatibility, so is not acceptable)

sonots commented 5 years ago

My current workaround is to do as:

ids=$(digdag schedules | grep id | awk -F: '{print $2}')
echo "${ids}" | xargs -I{} digdag reschedule {} --skip-to "$(date '+%Y-%m-%d %H:%M:%S %z')"

then, digdag enable all projects.