Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support/standardise stdin plugins #184

Open
absolutejam opened this issue Dec 14, 2017 · 0 comments
Open

Support/standardise stdin plugins #184

absolutejam opened this issue Dec 14, 2017 · 0 comments

Comments

@absolutejam
Copy link

absolutejam commented Dec 14, 2017

So, v1.1.0 brought about the new stdin check attribute, which I for one completely missed until recently. However, I see some awesome possibilities presented with this feature as it presents the ability to parse richer data structures (Which I've been dying for!).

Check STDIN. A boolean check definition attribute, "stdin", when set to true instructs the Sensu client to write JSON serialized Sensu client and check definition data to the check command process STDIN. This attribute cannot be used with existing Sensu check plugins, nor Nagios plugins etc, as the Sensu client will wait indefinitely for the check process to read and close STDIN.

Now, to best support this style of check, we'll need to provide some changes to the base class. Once we've decided here, I can also implement in sensu-plugins-python too.

Proposed

  • Require the --stdin flag to differentiate between a regular check and stdin, as both modes can be supported by the same check.
  • Require/suggest a method of storing 'required' and 'optional' JSON fields.
  • Provide examples and example tests for plugin developers.
  • @majormoses This could also link in with discussions we've had about improving metadata on plugins?

Anything else to suggest?

@absolutejam absolutejam changed the title Support/standardise stdtin plugins Support/standardise stdin plugins Dec 14, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant