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

chore: reword jsonschema extension docs #9965

Merged
merged 1 commit into from
Oct 1, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 8 additions & 7 deletions master/pkg/schemas/extensions/checks.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,15 @@
// A jsonschema extension consists of three parts:
//
// - A compile function. Compiling happens once before any validations and takes the schema as
// input. The extension's compile function will be called each time the extension appears in
// the schema. The return value of the compile function will be fed to the validation function.
// input. The extension's compile function will be called once for each time the extension
// appears in the schema. The return value of the compile function will be fed to the validation
// function.
//
// - A validate function. Validation happens once for each instance of data that is checked. The
// extension's validate function is called once for each time the compile function was caused,
// for each overall validation. Each call to the validate function receives the output from one
// call to the compile function and corresponds to a particular appearance of the extension in
// the schema.
// - A validate function. Validation happens once for each instance of data that is checked.
// During a validation, the validate function will be called as many times as the extension
// appeared in the schema. Each call to the validate function receives the output from one call
// to the compile function and corresponds to a particular appearance of the extension in the
// schema.
//
// - A metaschema which describes how the *schema* that uses the extension is allowed to look.

Expand Down
Loading