Open halcyonardency opened 8 years ago
+1
What do you mean with 'extension'? I'd happily merge PR's for better dealing with failures.
I have seen similar issues, mainly I would just like it if the handler would keep trying in a graceful way and let me know how many times it failed once it finally does reach slack.
@xyntrix Did you ever happen to start your PR?
If anyone wants to create this an extension there is a new https://github.com/sensu-extensions org and I would be more than happy to setup a repo and merge a sane PR.
Hi. I have just created a pull request for the multi-channel version of the handler which includes, among others, the implementation of a retry & timeout strategy in contacting the slack api. Have a look at https://github.com/sensu-plugins/sensu-plugins-slack/pull/82/files#diff-0f8d1e04e6833eb356bb3b51869ef271R266 I believe this would solve the issue mentioned here. I am willing to add this to the main handler and also allow for customizing these values (retries, timeout and wait_time) in the handler config. I know this is an old issue, but I'm sure more people can be hitting the issue as we were.
The default Slack handler sometimes hangs if the network fails, leading to high load on the Sensu server.
I will be submitting a PR for rewriting this as an extension with a few protections around failure conditions.