pub enum FailValueRequirement {
Show 24 variants
SchemaType(String),
SchemaTypeEvenNull(String),
TruthyImpliesSchemaType(String),
HelmTruthy,
HelmFalsy,
FieldHelmFalsy {
path: Vec<String>,
},
FieldEquals {
path: Vec<String>,
value: GuardValue,
},
FieldPresentNotNull {
path: Vec<String>,
},
FieldHelmTruthy {
path: Vec<String>,
},
AnyOf(Vec<Vec<FailValueRequirement>>),
NotEquals(GuardValue),
FieldNotEquals {
path: Vec<String>,
value: GuardValue,
},
ComparableKind(String),
NotSchemaType(String),
HasMember(String),
HasMemberEvenDefaulted(String),
MatchesPattern {
pattern: String,
templated: bool,
},
NotMatchesPattern {
pattern: String,
},
StringLengthBounds {
min: Option<u64>,
max: Option<u64>,
},
MemberHost {
handled_kinds: Vec<String>,
},
Iterable {
allow_integer: bool,
},
IndexableAt(usize),
SplitSegmentsAtLeast {
separator: String,
segments: usize,
allow_non_string: bool,
},
QuotedSerializationSafe {
style: QuotedScalarStyle,
},
}Expand description
One requirement a fail branch imposes on an affected value.
Variants§
SchemaType(String)
The value must be of this JSON Schema type.
SchemaTypeEvenNull(String)
The value must be of this JSON Schema type EVEN WHEN NULL: the
consumer type-asserts before any nil check (Sprig dig subjects),
so an explicit null aborts while structural absence stays open
through the arm’s properties anchoring.
TruthyImpliesSchemaType(String)
The value must be of this JSON Schema type only when Helm-truthy:
every falsy spelling escapes through the consumer’s own truthiness
selection (a ranged ACL member’s default "" password reaching
sha256sum behind if $password).
HelmTruthy
The value must be Helm-truthy (sealed-secrets aborts on any falsy
privateKeyAnnotations member, including the empty string).
HelmFalsy
The value must be Helm-FALSY — the negation of a member’s own
truthiness test inside a compound ranged terminal: the fail fires
only for truthy members, so falsiness is one escape alternative
(traefik’s if $config gate around the http3-without-tls abort).
FieldHelmFalsy
The value’s field at path, when present, must be Helm-FALSY: the
failing test fired on the field’s truthiness (oauth2-proxy aborts
when a legacy extraPaths[].backend.serviceName is set under the
networking.k8s.io/v1 Ingress api).
FieldEquals
The value must be an object whose field at path is present and
equals the literal: the failing test’s negation held an equality on
the field (traefik’s eq $plugin.type "hostPath" dispatch arm; Go’s
eq aborts on a nil operand, so presence rides along).
Fields
value: GuardValueLiteral required at the field path.
FieldPresentNotNull
The value must be an object whose field at path is present and
non-null: a ranged member’s leaf renders into a provider-REQUIRED
resource field, where a missing or null source emits an explicit
null the provider rejects (promtail’s extra Service port).
FieldHelmTruthy
The value must be an object whose field at path is present and
Helm-truthy — the positive mirror of Self::FieldHelmFalsy, used
as the ESCAPE alternative when a member-scoped branch guard selects
another render for truthy fields (promtail’s service arm renders
its own port instead of containerPort).
AnyOf(Vec<Vec<FailValueRequirement>>)
At least one alternative (each a conjunction of requirements) must
hold. A fail whose test conjoins several member conditions negates
to the DISJUNCTION of their negations — traefik’s local plugins
render with a truthy type OR a legacy truthy hostPath, and
conjoining those requirements rejected both documented shapes.
NotEquals(GuardValue)
The value must not equal this literal (cilium forbids ranged
extraEnv names colliding with its own backoff variables).
FieldNotEquals
The value’s field at path, when present, must differ from the
literal — the negation of a member-field equality test. Absent and
null fields differ from every literal (Helm’s eq compares nil
without aborting), so no presence requirement rides along
(traefik’s HTTPS-protocol listeners must carry certificateRefs;
non-HTTPS listeners escape through this arm).
Fields
value: GuardValueLiteral excluded at the field path.
ComparableKind(String)
The value must be of this JSON Schema type IF present and non-null:
Go’s eq/ne compare nil against anything, so a missing or null
comparison operand renders while a present value of a different
basic kind aborts.
NotSchemaType(String)
The value must NOT be of this JSON Schema type.
HasMember(String)
The value must be an object containing this member.
HasMemberEvenDefaulted(String)
The value must be an object containing this member EVEN when the
chart’s own defaults supply it: the consumer aborts on an absent
subject (a nil dig dict), and under coalesced-document semantics
the member is absent exactly when a user null-deletes it — the
state the requirement must reject. Exempt from the
default-supplied required relaxation that render-grade presence
claims get.
MatchesPattern
The value must be a string matching this regular expression
(regexMatch type-asserts a string subject, so string-ness rides
along).
Fields
NotMatchesPattern
The value must be a string NOT matching this regular expression —
the failing test fired on matches, and its regexMatch still
type-asserts a string subject (traefik’s uppercase key gate).
StringLengthBounds
The value must be a string whose length lies inside the window — a
provider key slot’s minLength/maxLength projected onto a ranged
collection’s keys (traefik’s Gateway listener names).
Fields
MemberHost
The value HOSTS literal member reads: it must be an object — or one
of the kinds the chart’s own type dispatch provably handles before
the reads run (nack converts the string image form with set).
Iterable
The value is iterated by range: collections and nil render, and
integer counts iterate when the loop body has no member structure.
IndexableAt(usize)
A zero-based position must exist before index can project it.
Arrays lower exactly; strings remain conservative because Go indexes
bytes while JSON Schema minLength counts Unicode code points.
SplitSegmentsAtLeast
Splitting the textual form must produce at least segments entries.
When the input was first passed through a total text conversion,
non-string inputs remain conservatively accepted.
Fields
QuotedSerializationSafe
The value renders inside a manually quoted YAML scalar: every string
it contributes to the token — the value itself, or any nested string
or mapping key when Go’s fmt serializes a collection
(map[k:v] / [a b]) with its strings embedded raw — must be valid
content for the quoting style. Non-string scalars format as plain
digits/words and are always safe.
Fields
style: QuotedScalarStyleYAML quoting grammar that serialized content must satisfy.
Trait Implementations§
Source§impl Clone for FailValueRequirement
impl Clone for FailValueRequirement
Source§fn clone(&self) -> FailValueRequirement
fn clone(&self) -> FailValueRequirement
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more