pub enum Error {
Show 15 variants
Storage(String),
Serialization(String),
NodeNotFound(String),
SessionNotFound(String),
InvalidNodeType {
expected: String,
actual: String,
},
ValidationError(String),
TraversalError(String),
ConfigError(String),
Io(Error),
RuntimeError(String),
Timeout(u64),
ConcurrentModification(String),
PoolExhausted,
Metrics(String),
Other(String),
}Expand description
Error types that can occur during graph operations
Variants§
Storage(String)
Storage backend error
Serialization(String)
Serialization/deserialization error
NodeNotFound(String)
Node not found error
SessionNotFound(String)
Session not found error
InvalidNodeType
Invalid node type error
ValidationError(String)
Schema validation error
TraversalError(String)
Graph traversal error
ConfigError(String)
Configuration error
Io(Error)
I/O error
RuntimeError(String)
Async runtime error
Timeout(u64)
Async operation timeout
ConcurrentModification(String)
Concurrent modification conflict
PoolExhausted
Connection pool exhausted
Metrics(String)
Metrics error
Other(String)
Generic error
Implementations§
Source§impl Error
impl Error
Sourcepub fn timeout(duration_ms: u64) -> Self
pub fn timeout(duration_ms: u64) -> Self
Create a timeout error with the specified duration in milliseconds
Sourcepub fn concurrent_modification<S: Into<String>>(context: S) -> Self
pub fn concurrent_modification<S: Into<String>>(context: S) -> Self
Create a concurrent modification error with context
Sourcepub fn pool_exhausted() -> Self
pub fn pool_exhausted() -> Self
Create a pool exhausted error
Sourcepub fn is_timeout(&self) -> bool
pub fn is_timeout(&self) -> bool
Check if this error is a timeout
Sourcepub fn is_concurrent_modification(&self) -> bool
pub fn is_concurrent_modification(&self) -> bool
Check if this error is a concurrent modification
Sourcepub fn is_pool_exhausted(&self) -> bool
pub fn is_pool_exhausted(&self) -> bool
Check if this error is pool exhausted
Sourcepub fn is_retryable(&self) -> bool
pub fn is_retryable(&self) -> bool
Check if this error is retryable
Trait Implementations§
Source§impl Error for Error
impl Error for Error
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()
Auto Trait Implementations§
impl Freeze for Error
impl !RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl !UnwindSafe for Error
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