-
Notifications
You must be signed in to change notification settings - Fork 32
Open
Description
Up till now, we use kitchen-sink.yaml as a blunt instrument to:
- Demonstrate the full configuration surface area of the schema
- Validate that the schema works as we expect (i.e.
make validate-examples)
This is results in a variety of problems:
kitchen-sink.yamlis huge!- Despite our best effort,
kitchen-sink.yamlcan't express all the configurable surface area. For example, see Add schema for composite sampler #390 using bits of the parent based sampler configuration, which has 5 configurable sampler properties, to express a new sampler. kitchen-sink.yamlconfiguration is often nonsensical, as a result of the effort to document all the surface area.kitchen-sink.yamlis annotated with comments generated from the JSON schema and meta schema, which is good for consistency, but limits our ability to convey bits of information about a specific example to users.
I think what we really need is:
- A directory of snippets, e.g.
/snippets - Where each file in
/snippetscontains a narrow demonstration of a particular piece of the larger schema - With build tooling which validates that each file adheres to the particular type it is demonstrating, leveraging a file naming convention of the form
{type}_{snippet_description}.yamlwith build tooling validating according to the{type}extracted from the file name. - Where snippets do not contain generated comments from the JSON schema and meta schema, but instead only include ad-hoc comments where needed
- The generated schema-docs.md could leverage these snippets to detect usages of each type, and either link over to those snippets or directly embed their contents in the markdown.
- And where this tooling ultimately allows
kitchen-sink.yamlto be deleted, as it is essentially decomposed into a bunch of smaller focussed pieces.
Metadata
Metadata
Assignees
Labels
No labels