Closed makaveli0129 closed 6 years ago
do you have a require for this? https://github.com/sensu/sensu-extension/blob/master/lib/sensu/extension.rb there is no similar logger I see for plugin.
Because extensions run inside the EventMachine loop, they have access to the logger. Plugins run as a child process so they do not have access to the logger. Output for both check and handler plugins should be sent to stdout so that Sensu can capture and log it.
I don't think there's anything we can do for this request for the reasons described above. Closing.
With the plugin CLI i am trying to use the "logger" in the same way that we do for extensions but i keep getting errors that Sensu::Logger.get is not valid. I'm assuming i am doing something wrong but could not find an example of a plugin that uses the sensu-client logger. Is there a way to do this?