Mailing List Archive

[oslo] Config Validator
Hi,

We recently merged a new feature to oslo.config and it was suggested
that I publicize it since it addresses a longstanding pain point. It's a
validator tool[1] that will warn or error on any entries in a config
file that aren't defined in the service or are deprecated.

Previously this was difficult to do accurately because config opts are
registered at runtime and you don't know for sure when all of the opts
are present. This tool makes use of the less recently added
machine-readable sample config[2], which should contain all of the
available opts for a service. If any are missing, that is a bug and
should be addressed in the service anyway. This is the same data used to
generate sample config files and those should have all of the possible
opts listed.

The one limitation I'm aware of at this point is that dynamic groups
aren't handled, so options in a dynamic group will be reported as
missing even though they are recognized by the service. This should be
solvable, but for the moment it is a limitation to keep in mind.

So if this is something you were interested in, please try it out and
let us know how it works for you. The latest release of oslo.config on
pypi should have this tool, and since it doesn't necessarily have to be
run on the live system you can install the bleeding edge oslo.config
somewhere else and just generate the machine readable sample config from
the production system. That functionality has been in oslo.config for a
few cycles now so it's more likely to be available.

Thanks.

-Ben

1: https://docs.openstack.org/oslo.config/latest/cli/validator.html
2:
https://docs.openstack.org/oslo.config/latest/cli/generator.html#machine-readable-configs

_______________________________________________
OpenStack-operators mailing list
OpenStack-operators@lists.openstack.org
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-operators