Enum ApprovalSource
#[non_exhaustive]pub enum ApprovalSource {
Operator,
Unavailable,
Unreachable,
TimedOut,
}Expand description
Who decided an approval outcome.
Everything other than ApprovalSource::Operator is the runtime denying on
its own authority. Callers reporting a denial to a model must distinguish
them: an operator’s “no” is a decision, while the rest are the absence of
one, and telling a model a human refused when none was asked sends it
looking for a decision that never happened.
#[non_exhaustive] so a later provenance category is an additive change:
out-of-tree matches must already carry a wildcard arm, and Operator is the
Default so an out-of-tree constructor that does not care about
provenance keeps the pre-existing “a person answered” meaning.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Operator
A human answered through a channel.
No approval-capable channel was available: none connected, or the channel does not implement approval prompts.
Unreachable
An approver was configured but could not be reached, errored, or returned no decision.
TimedOut
An approver was reachable but did not answer within the route’s budget.
Implementations§
Source§impl ApprovalSource
impl ApprovalSource
Sourcepub fn is_runtime_fail_closed(self) -> bool
pub fn is_runtime_fail_closed(self) -> bool
True when the runtime produced this outcome itself, so no operator decision exists to report.
Trait Implementations§
Source§impl Clone for ApprovalSource
impl Clone for ApprovalSource
Source§fn clone(&self) -> ApprovalSource
fn clone(&self) -> ApprovalSource
1.0.0 (const: unstable) · §fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more