Documentation
¶
Index ¶
Constants ¶
const XExtendKey = "x-extend"
XExtendKey is the OpenAPI extension key that signals schema inheritance. When present, the child schema is merged with the parent provided to Extend.
const XRequiredForHelm = "x-required-for-helm"
XRequiredForHelm is the OpenAPI extension key whose value is a field name or list of field names that must be present in the Helm values document.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AdditionalProperties ¶
AdditionalProperties is a Transformer that sets AdditionalProperties to false on every object schema node that does not already define it. This prevents values documents from containing undeclared keys that would otherwise pass validation silently.
type Copy ¶
type Copy struct{}
Copy is a Transformer that produces a deep clone of a schema via a JSON marshal/unmarshal round-trip. Used before mutations that must not affect the original schema object (e.g. before RequiredForHelm).
type Extend ¶
Extend is a Transformer that merges a parent schema into the child schema when the child carries an x-extend extension. The child's own values take precedence over the parent's for all merged fields.
type ExtendSettings ¶
type ExtendSettings struct {
Schema *string `json:"schema,omitempty"`
}
ExtendSettings holds the parsed contents of an x-extend extension block. Schema names the parent schema document to inherit from (reserved for future multi-parent support; currently the parent is passed directly to Extend).
type RequiredForHelm ¶
type RequiredForHelm struct{}
RequiredForHelm is a Transformer that promotes field names listed in the x-required-for-helm extension into the standard required array. This makes those fields mandatory at Helm rendering time even if they are optional in the regular values schema (e.g. fields that Helm templates always dereference).