You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
when attempting to create the sample handler: sensu::handler { 'slack': type => 'pipe', command => "/opt/sensu/embedded/bin/handler-slack.rb", config => { 'webhook_url' => 'https://hooks.slack.com/services/###/###/###', 'template' => '', } }
the resulting created yaml will contain an empty "filter" entry. Despite being empty, this causes the same error to repeat in the sensu logs while evaluating the handler:
{"timestamp":"2017-03-16T09:41:35.902187-0700","level":"info","message":"handler output","handler":{"command":"/opt/sensu/embedded/bin/handler-slack.rb","type":"pipe","filters":[],"severities":["ok","warning","critical","unknown"],"name":"slack"},"output":["warning: event filtering in sensu-plugin is deprecated, see http://bit.ly/sensu-plugin\nwarning: occurrence filtering in sensu-plugin is deprecated, see http://bit.ly/sensu-plugin\nonly handling every 30 occurrences:"]}
Manually editing the yaml and pulling out the empty filters entry suppress the message, but it seems like something that should likely be cleaned out.
The text was updated successfully, but these errors were encountered:
Hi @Justin-DynamicD, the filter deprecation warnings you describe are a product of changes in the sensu-plugin library, and are not related to the presence or absence of filters in the handler definition.
perhaps my explanation is poor, but the link provided describes the exact problem as well as my suggestion: eventually remove the filtering from sensu::handler, so it sounds like it's being worked on.
To clarify, however: Even if the resulting value is left empty, merely declaring "filters" in the handler yaml file will generate the warning in the sensu-server log. So while it may not be the "root cause", the way sensu::handler generates it's yaml causes the "filters" to always be defined in the yaml and thus the warning to always appear in the log.
when attempting to create the sample handler:
sensu::handler { 'slack': type => 'pipe', command => "/opt/sensu/embedded/bin/handler-slack.rb", config => { 'webhook_url' => 'https://hooks.slack.com/services/###/###/###', 'template' => '', } }the resulting created yaml will contain an empty "filter" entry. Despite being empty, this causes the same error to repeat in the sensu logs while evaluating the handler:
{"timestamp":"2017-03-16T09:41:35.902187-0700","level":"info","message":"handler output","handler":{"command":"/opt/sensu/embedded/bin/handler-slack.rb","type":"pipe","filters":[],"severities":["ok","warning","critical","unknown"],"name":"slack"},"output":["warning: event filtering in sensu-plugin is deprecated, see http://bit.ly/sensu-plugin\nwarning: occurrence filtering in sensu-plugin is deprecated, see http://bit.ly/sensu-plugin\nonly handling every 30 occurrences:"]}Manually editing the yaml and pulling out the empty filters entry suppress the message, but it seems like something that should likely be cleaned out.
The text was updated successfully, but these errors were encountered: