#[non_exhaustive]pub enum NewSessionError {
Show 18 variants
FailedToResolveAnyHostname(Vec<String>),
EmptyKnownNodesList,
DbError(DbError, String),
BadQuery(BadQuery),
CqlRequestSerialization(CqlRequestSerializationError),
EmptyPlan,
BodyExtensionsParseError(FrameBodyExtensionsParseError),
MetadataError(MetadataError),
CqlResultParseError(CqlResultParseError),
CqlErrorParseError(CqlErrorParseError),
ConnectionPoolError(ConnectionPoolError),
ProtocolError(ProtocolError),
TimeoutError,
BrokenConnection(BrokenConnectionError),
UnableToAllocStreamId,
RequestTimeout(String),
NextRowError(NextRowError),
IntoLegacyQueryResultError(IntoLegacyQueryResultError),
}
Expand description
Error that occurred during session creation
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
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
CqlRequestSerialization(CqlRequestSerializationError)
Failed to serialize CQL request.
EmptyPlan
Load balancing policy returned an empty plan.
BodyExtensionsParseError(FrameBodyExtensionsParseError)
Failed to deserialize frame body extensions.
MetadataError(MetadataError)
Failed to perform initial cluster metadata fetch.
CqlResultParseError(CqlResultParseError)
Received a RESULT server response, but failed to deserialize it.
CqlErrorParseError(CqlErrorParseError)
Received an ERROR server response, but failed to deserialize it.
ConnectionPoolError(ConnectionPoolError)
Selected node’s connection pool is in invalid state.
ProtocolError(ProtocolError)
Protocol error.
TimeoutError
Timeout error has occurred, couldn’t connect to node in time.
BrokenConnection(BrokenConnectionError)
A connection has been broken during query execution.
UnableToAllocStreamId
Driver was unable to allocate a stream id to execute a query on.
RequestTimeout(String)
Client timeout occurred before a response arrived for some query
during Session
creation.
NextRowError(NextRowError)
An error occurred during async iteration over rows of result.
IntoLegacyQueryResultError(IntoLegacyQueryResultError)
Failed to convert QueryResult
into LegacyQueryResult
.
Trait Implementations§
Source§impl Clone for NewSessionError
impl Clone for NewSessionError
Source§fn clone(&self) -> NewSessionError
fn clone(&self) -> NewSessionError
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
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)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
Source§impl From<BadQuery> for NewSessionError
impl From<BadQuery> for NewSessionError
Source§impl From<BrokenConnectionError> for NewSessionError
impl From<BrokenConnectionError> for NewSessionError
Source§fn from(source: BrokenConnectionError) -> Self
fn from(source: BrokenConnectionError) -> Self
Source§impl From<ConnectionPoolError> for NewSessionError
impl From<ConnectionPoolError> for NewSessionError
Source§fn from(source: ConnectionPoolError) -> Self
fn from(source: ConnectionPoolError) -> Self
Source§impl From<CqlErrorParseError> for NewSessionError
impl From<CqlErrorParseError> for NewSessionError
Source§fn from(source: CqlErrorParseError) -> Self
fn from(source: CqlErrorParseError) -> Self
Source§impl From<CqlRequestSerializationError> for NewSessionError
impl From<CqlRequestSerializationError> for NewSessionError
Source§fn from(source: CqlRequestSerializationError) -> Self
fn from(source: CqlRequestSerializationError) -> Self
Source§impl From<CqlResultParseError> for NewSessionError
impl From<CqlResultParseError> for NewSessionError
Source§fn from(source: CqlResultParseError) -> Self
fn from(source: CqlResultParseError) -> Self
Source§impl From<FrameBodyExtensionsParseError> for NewSessionError
impl From<FrameBodyExtensionsParseError> for NewSessionError
Source§fn from(source: FrameBodyExtensionsParseError) -> Self
fn from(source: FrameBodyExtensionsParseError) -> Self
Source§impl From<IntoLegacyQueryResultError> for NewSessionError
impl From<IntoLegacyQueryResultError> for NewSessionError
Source§fn from(source: IntoLegacyQueryResultError) -> Self
fn from(source: IntoLegacyQueryResultError) -> Self
Source§impl From<MetadataError> for NewSessionError
impl From<MetadataError> for NewSessionError
Source§fn from(source: MetadataError) -> Self
fn from(source: MetadataError) -> Self
Source§impl From<NextRowError> for NewSessionError
impl From<NextRowError> for NewSessionError
Source§fn from(source: NextRowError) -> Self
fn from(source: NextRowError) -> Self
Source§impl From<ProtocolError> for NewSessionError
impl From<ProtocolError> for NewSessionError
Source§fn from(source: ProtocolError) -> Self
fn from(source: ProtocolError) -> Self
Source§impl From<QueryError> for NewSessionError
impl From<QueryError> for NewSessionError
Source§fn from(query_error: QueryError) -> NewSessionError
fn from(query_error: QueryError) -> NewSessionError
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
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>
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>
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