pub enum AuthorizationError<Resolve, Audit> {
Context(ContextError),
PolicyHash(Error),
Resolve(ResolveError<Resolve>),
FactResolutionEvidence(FactResolutionEvidenceError),
AuditEntry(AuditEntryError),
Trace(TraceError),
Occurrence(DecisionAuditOccurrenceError),
Audit {
occurrence: DecisionAuditOccurrence,
source: Audit,
},
}Expand description
Error produced while resolving, evaluating, tracing, or auditing a decision.
Variants§
Context(ContextError)
The request context failed tenant-binding validation before facts were resolved.
PolicyHash(Error)
Policy hashing failed before the decision could be anchored.
Resolve(ResolveError<Resolve>)
Fact resolution failed before evaluation.
FactResolutionEvidence(FactResolutionEvidenceError)
Resolved fact-set evidence could not be serialized.
AuditEntry(AuditEntryError)
The current audit entry failed its tenant-binding invariants.
Trace(TraceError)
Trace serialization failed after evaluation.
Occurrence(DecisionAuditOccurrenceError)
The captured decision occurrence could not cross the Dovecote time boundary without changing its meaning.
Audit
Audit recording failed.
Fields
§
occurrence: DecisionAuditOccurrenceReusable identity and occurrence time for an ambiguous retry.
§
source: AuditSink-specific failure.
Implementations§
Source§impl<Resolve, Audit> AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> AuthorizationError<Resolve, Audit>
Sourcepub const fn audit_occurrence(&self) -> Option<&DecisionAuditOccurrence>
pub const fn audit_occurrence(&self) -> Option<&DecisionAuditOccurrence>
Returns the occurrence that was used when audit persistence failed.
Trait Implementations§
Source§impl<Resolve, Audit> Display for AuthorizationError<Resolve, Audit>where
ResolveError<Resolve>: Display,
impl<Resolve, Audit> Display for AuthorizationError<Resolve, Audit>where
ResolveError<Resolve>: Display,
Source§impl<Resolve, Audit> Error for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> Error for AuthorizationError<Resolve, Audit>
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl<Resolve, Audit> From<AuditEntryError> for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> From<AuditEntryError> for AuthorizationError<Resolve, Audit>
Source§fn from(source: AuditEntryError) -> Self
fn from(source: AuditEntryError) -> Self
Converts to this type from the input type.
Source§impl<Resolve, Audit> From<ContextError> for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> From<ContextError> for AuthorizationError<Resolve, Audit>
Source§fn from(source: ContextError) -> Self
fn from(source: ContextError) -> Self
Converts to this type from the input type.
Source§impl<Resolve, Audit> From<DecisionAuditOccurrenceError> for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> From<DecisionAuditOccurrenceError> for AuthorizationError<Resolve, Audit>
Source§fn from(source: DecisionAuditOccurrenceError) -> Self
fn from(source: DecisionAuditOccurrenceError) -> Self
Converts to this type from the input type.
Source§impl<Resolve, Audit> From<FactResolutionEvidenceError> for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> From<FactResolutionEvidenceError> for AuthorizationError<Resolve, Audit>
Source§fn from(source: FactResolutionEvidenceError) -> Self
fn from(source: FactResolutionEvidenceError) -> Self
Converts to this type from the input type.
Source§impl<Resolve, Audit> From<ResolveError<Resolve>> for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> From<ResolveError<Resolve>> for AuthorizationError<Resolve, Audit>
Source§fn from(source: ResolveError<Resolve>) -> Self
fn from(source: ResolveError<Resolve>) -> Self
Converts to this type from the input type.
Source§impl<Resolve, Audit> From<TraceError> for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> From<TraceError> for AuthorizationError<Resolve, Audit>
Source§fn from(source: TraceError) -> Self
fn from(source: TraceError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl<Resolve, Audit> !RefUnwindSafe for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> !UnwindSafe for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> Freeze for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> Send for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> Sync for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> Unpin for AuthorizationError<Resolve, Audit>
impl<Resolve, Audit> UnsafeUnpin for AuthorizationError<Resolve, Audit>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more