pub enum ClientError {
EmptyToken,
InvalidCaPem,
ForceTlsPlaintextConflict,
PlaintextCaPemConflict,
CaPemParse(String),
InvalidEndpoint {
addr: String,
source: Error,
},
Connect {
addr: String,
source: Error,
},
ReadCaFile {
path: String,
source: Error,
},
}Expand description
Errors returned by the connection helpers in this module.
Variants§
EmptyToken
dial_admin was called with an empty (or whitespace-only) token.
InvalidCaPem
A CA PEM bundle was supplied but contained no parseable certificates.
ForceTlsPlaintextConflict
dial_admin was called with both force_tls and plaintext set.
They request opposite overrides of the loopback heuristic, so
exactly one (or neither) may be set. See dial_admin’s doc
comment.
PlaintextCaPemConflict
dial_admin was called with plaintext set and a non-empty
ca_pem. There is no meaningful CA to verify against when the
transport isn’t TLS at all. See dial_admin’s doc comment.
CaPemParse(String)
A CA PEM bundle was supplied but failed to parse.
InvalidEndpoint
The target address could not be turned into a valid gRPC endpoint URI.
Connect
Failed to establish the transport connection.
ReadCaFile
Reading a CA bundle from disk (see read_ca_file) failed.
Trait Implementations§
Source§impl Debug for ClientError
impl Debug for ClientError
Source§impl Display for ClientError
impl Display for ClientError
Source§impl Error for ClientError
impl Error for ClientError
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
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for ClientError
impl !UnwindSafe for ClientError
impl Freeze for ClientError
impl Send for ClientError
impl Sync for ClientError
impl Unpin for ClientError
impl UnsafeUnpin for ClientError
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request