Join GitHub today
DISCUSS: configuration validation #1244
Hello all. We would like to collect feedback and input on how Sensu deals with invalid configuration. There are currently two types of "invalid" configuration:
Unfortunately Sensu also currently behaves in two different ways when encountering invalid configuration:
We would like to settle on a single validation behavior for all invalid configuration scenarios. Should Sensu ignore invalid configuration (weak validation) and continue loading/running -OR- should Sensu reject invalid configuration and stop (strong validation)?
Please feel free to comment with your thoughts and/or vote using emoji reactions.
We're targeting the 0.25 release for configuration validation improvements, so we'll leave this issue open for a few weeks before we make a final decision.
Thanks in advance for your time & consideration. #monitoringlove
Allowing a flag to ignore invalid configs is an option, but when would having an incorrect configuration be a desired operating condition?
What about having a check_config command that would validate changes, this would allow you to restart with confidence knowing that your configs are ok.
@DerekSchenk as of Sensu 0.23 there is a new
I think the current behavior is optimal because:
In our scenario, we are a DevOps shop. Service Owners are responsible for, erm I mean, empowered to create their own monitoring. We're in the process replacing Nagios + check_mk with Sensu. We've had fairly good traction with getting people to write check_mk local checks, which helps enable a self-service, roll-your-own, monitoring model. They can iterate on their checks as they wish and leave the Nagios server-side alone. If they jack up a local check, then it only affects that particular check.
Fast forward to when we get the next-gen architecture in place, it means we have lots of folks who are new to Sensu. That means we have many, many opportunities for simple config mistakes as people come up to speed on Sensu. I fear torches and pitchforks if I move them to a model where a missing comma takes all of their monitoring offline.
In summary: I'd leave it the way it is.
Main improvement that comes to mind is sweeping the config before a service restart to call out any bad config before actually stopping any Sensu process.
$0.02 deposited :)
referenced this issue
Apr 28, 2016
@cjchand Thank you for the input!
I think using
Making the behaviour consistent between file and definition validation will be the big improvement, making the validation action configurable is the icing on the cake.
After having a go at Sensu settings validation that supports
This was referenced
May 2, 2016
This was implemented in 0.25 via
However, not all of the packages are taking advantage of