pub enum NewSessionError {
FailedToResolveAnyHostname(Vec<String>),
EmptyKnownNodesList,
DbError(DbError, String),
BadQuery(BadQuery),
IoError(Arc<Error>),
ProtocolError(&'static str),
InvalidMessage(String),
TimeoutError,
TooManyOrphanedStreamIds(u16),
UnableToAllocStreamId,
RequestTimeout(String),
TranslationError(TranslationError),
}
Expand description
Error that occurred during session creation
Variants§
FailedToResolveAnyHostname(Vec<String>)
Failed to resolve hostname passed in Session creation
EmptyKnownNodesList
List of known nodes passed to Session constructor is empty There needs to be at least one node to connect to
DbError(DbError, String)
Database sent a response containing some error with a message
BadQuery(BadQuery)
Caller passed an invalid query
IoError(Arc<Error>)
Input/Output error has occurred, connection broken etc.
ProtocolError(&'static str)
Unexpected message received
InvalidMessage(String)
Invalid message received
TimeoutError
Timeout error has occurred, couldn’t connect to node in time.
TooManyOrphanedStreamIds(u16)
UnableToAllocStreamId
RequestTimeout(String)
Client timeout occurred before a response arrived for some query
during Session
creation.
TranslationError(TranslationError)
Address translation failed
Trait Implementations§
Source§impl Clone for NewSessionError
impl Clone for NewSessionError
Source§fn clone(&self) -> NewSessionError
fn clone(&self) -> NewSessionError
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for NewSessionError
impl Debug for NewSessionError
Source§impl Display for NewSessionError
impl Display for NewSessionError
Source§impl Error for NewSessionError
impl Error for NewSessionError
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 From<BadQuery> for NewSessionError
impl From<BadQuery> for NewSessionError
Source§fn from(source: BadQuery) -> NewSessionError
fn from(source: BadQuery) -> NewSessionError
Converts to this type from the input type.
Source§impl From<Error> for NewSessionError
impl From<Error> for NewSessionError
Source§fn from(io_error: Error) -> NewSessionError
fn from(io_error: Error) -> NewSessionError
Converts to this type from the input type.
Source§impl From<QueryError> for NewSessionError
impl From<QueryError> for NewSessionError
Source§fn from(query_error: QueryError) -> NewSessionError
fn from(query_error: QueryError) -> NewSessionError
Converts to this type from the input type.
Source§impl From<TranslationError> for NewSessionError
impl From<TranslationError> for NewSessionError
Source§fn from(source: TranslationError) -> NewSessionError
fn from(source: TranslationError) -> NewSessionError
Converts to this type from the input type.
Auto Trait Implementations§
impl !Freeze for NewSessionError
impl !RefUnwindSafe for NewSessionError
impl Send for NewSessionError
impl Sync for NewSessionError
impl Unpin for NewSessionError
impl !UnwindSafe for NewSessionError
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more