Hi community,
thanks again for the great project
I was thinking of my usage of notify
and handlers
. I don’t use them much and I find myself rewriting the pattern by inserting some “restart” actions in the middle of my tasks. And then, I also write some “changes detectors” to run those restarts conditionally… kind of re-doing what the notify / handlers does.
Why am I not using the notify / handlers, then ? It’s because I can’t control where and when it’s going to be handled… What would fit my use case, would be to have something like:
- name: Trigger restarts
action: apply_notifies
or
- apply_notifies: $item
with_items: - restart this service
- restart that service
and then, if it was notified only… it would run that handler.
Would that be complex to build, or useful to any ?
Thanks!
Alexandre