pub enum Error {
Io {
kind: IoErrorKind,
message: String,
},
Protocol(Cow<'static, str>),
Encoding(Cow<'static, str>),
Conversion(Cow<'static, str>),
Utf8,
Utf16,
ParseInt(ParseIntError),
Server(TokenError),
Tls(String),
Gssapi(String),
Routing {
host: String,
port: u16,
},
BulkInput(Cow<'static, str>),
}
Expand description
A unified error enum that contains several errors that might occurr during the lifecycle of this driver
Variants
Io
Fields
kind: IoErrorKind
A list specifying general categories of I/O error.
message: String
The error description.
An error occured when performing I/O to the server.
Protocol(Cow<'static, str>)
An error happened during the request or response parsing.
Encoding(Cow<'static, str>)
Server responded with encoding not supported.
Conversion(Cow<'static, str>)
Conversion failure from one type to another.
Utf8
Tried to convert data to UTF-8 that was not valid.
Utf16
Tried to convert data to UTF-16 that was not valid.
ParseInt(ParseIntError)
Tried to parse an integer that was not an integer.
Server(TokenError)
An error returned by the server.
Tls(String)
An error in the TLS handshake.
Gssapi(String)
integrated-auth-gssapi
only.An error from the GSSAPI library.
Routing
Server requested a connection to an alternative address.
BulkInput(Cow<'static, str>)
Invalid input in Bulk Upload
Trait Implementations
sourceimpl Error for Error
impl Error for Error
1.30.0 · sourcefn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
sourcefn backtrace(&self) -> Option<&Backtrace>
fn backtrace(&self) -> Option<&Backtrace>
backtrace
)Returns a stack backtrace, if available, of where this error occurred. Read more
1.0.0 · sourcefn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
sourceimpl From<FromUtf16Error> for Error
impl From<FromUtf16Error> for Error
sourcefn from(_err: FromUtf16Error) -> Error
fn from(_err: FromUtf16Error) -> Error
Converts to this type from the input type.
sourceimpl From<FromUtf8Error> for Error
impl From<FromUtf8Error> for Error
sourcefn from(_err: FromUtf8Error) -> Error
fn from(_err: FromUtf8Error) -> Error
Converts to this type from the input type.
sourceimpl From<Infallible> for Error
impl From<Infallible> for Error
sourcefn from(_: Infallible) -> Self
fn from(_: Infallible) -> Self
Converts to this type from the input type.
sourceimpl From<ParseIntError> for Error
impl From<ParseIntError> for Error
sourcefn from(err: ParseIntError) -> Error
fn from(err: ParseIntError) -> Error
Converts to this type from the input type.
Auto Trait Implementations
impl RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnwindSafe for Error
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more