MCPcopy Create free account
hub / github.com/rilldata/rill / JSONSchemaForRillYAML

Function JSONSchemaForRillYAML

runtime/parser/schema.go:44–55  ·  view source on GitHub ↗

JSONSchemaForRillYAML returns the JSON schema for validating rill.yaml files.

()

Source from the content-addressed store, hash-verified

42
43// JSONSchemaForRillYAML returns the JSON schema for validating rill.yaml files.
44func JSONSchemaForRillYAML() (*jsonschema.Schema, error) {
45 // Ensure the schema is parsed
46 parsedRillYAMLSchemaOnce.Do(func() {
47 var err error
48 parsedRillYAMLSchema, err = parseSchemaFromYAML(rillYAMLSchema)
49 if err != nil {
50 panic(fmt.Sprintf("failed to parse schema: %v", err))
51 }
52 })
53
54 return parsedRillYAMLSchema, nil
55}
56
57// JSONSchemaForResourceType returns a JSON schema for validating the properties of a given resource type.
58// Note: You can use ParseResourceKind to get the ResourceKind from a string.

Callers 2

jsonSchemaForResourceFunction · 0.92

Calls 2

parseSchemaFromYAMLFunction · 0.85
DoMethod · 0.80

Tested by 1