I think this is a wonderful plan, and fully support it.
For the approach of taking this also to YAML, I have had some decent
experience with Rx (http://rx.codesimply.com/index.html) in producing
schema validation that is coherent between YAML and JSON.
I am not suggesting an alternative to json_shape, incidentally, but
rather than someone else might have found the rough edges of applying
the same schema to both...
Regards,
Daniel
On Mon, Mar 7, 2011 at 13:32, Paul Berry <[email protected]> wrote:
> Puppet currently produces and consumes data in several formats which:
> - are not explicitly documented
> - are sometimes modified by mistake (e.g. when a developer adds a private
> instance variable to a class, and that instance variable gets automatically
> serialized to YAML)
> - are sometimes modified without a full appreciation of the consequences of
> the changes (e.g. a format change is introduced which creates
> incompatibilities between old and new versions of Puppet, or between
> desynchronized versions of Puppet and Dashboard).
> Jesse Wolfe, Markus Roberts, Randall Hansen, and I had a discussion the
> other day about how to improve this situation, and we have a proposal for a
> first step. This initial proposal affects Puppet's JSON formats only:
> - Vendor the "json_shape" library, a lightweight JSON schema validator
> (https://github.com/jes5199/json_shape).
> - Create a subdirectory of the Puppet project called "serialization_schema"
> in which we store schemas for the various JSON data formats used by Puppet.
> - Create spec tests which validate each of Puppet's JSON output formats
> against these schemas.
> - Publish the contents of the "serialization_schema" directory on our web
> site so that users and 3rd party developers will know how what to expect
> from our data formats.
> - Subject the contents of the "serialization_schema" directory to a more
> rigid change control process than the rest of Puppet, so that we don't
> unintentionally introduce changes to our file formats while fixing bugs and
> adding features.
> Our hope is that once this is implemented we can build similar techniques to
> address YAML formats.
> Comments welcome.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Puppet Developers" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/puppet-dev?hl=en.
>
--
⎋ Puppet Labs Developer – http://puppetlabs.com
✉ Daniel Pittman <[email protected]>
✆ Contact me via gtalk, email, or phone: +1 (877) 575-9775
♲ Made with 100 percent post-consumer electrons
--
You received this message because you are subscribed to the Google Groups
"Puppet Developers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/puppet-dev?hl=en.