pub enum DomainErrorKind {
NotFound,
Conflict(String),
Internal(String),
}Expand description
Canonical error-kind shape for domain errors that need to cross the Connect RPC boundary.
Services implementing IntoDomainErrorKind on their own error types gain a
zero-boilerplate domain_to_connect mapper — no per-service re-implementation
of the DomainError → ConnectError translation table (ADR-0096).
§Variants
NotFound— resource absent; maps toConnectError::not_found.Conflict(String)— state conflict (e.g. duplicate key); maps toConnectError::already_exists.Internal(String)— unexpected error; logged viatracing::error!then mapped toConnectError::internalwith a generic message (no internal detail surfaced to callers).
Variants§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for DomainErrorKind
impl RefUnwindSafe for DomainErrorKind
impl Send for DomainErrorKind
impl Sync for DomainErrorKind
impl Unpin for DomainErrorKind
impl UnsafeUnpin for DomainErrorKind
impl UnwindSafe for DomainErrorKind
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