pub enum StatsdError {
InvalidHost,
InvalidPortZero,
MetricError {
source: MetricError,
},
IoError(Error),
RecorderError {
source: SetRecorderError<StatsdRecorder>,
},
}
Variants§
InvalidHost
This error indicates that the caller has supplied an invalid/empty host name.
InvalidPortZero
The caller specified port 0. In TCP/UDP programming generally, this is sometimes used to tell the system “pick a port for me”, but we don’t support it.
MetricError
MetricError indicates that there was an error reporting metrics to statsd, this is directly
mapped from cadence::MetricError
.
Fields
§
source: MetricError
IoError(Error)
Any I/O-related errors, e.g. UDP connection/bind errors.
RecorderError
An error indicating that there was a problem registering StatsdRecorder
with the
[metrics-rs
] system.
Fields
§
source: SetRecorderError<StatsdRecorder>
Trait Implementations§
Source§impl Debug for StatsdError
impl Debug for StatsdError
Source§impl Display for StatsdError
impl Display for StatsdError
Source§impl Error for StatsdError
impl Error for StatsdError
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<Error> for StatsdError
impl From<Error> for StatsdError
Source§impl From<MetricError> for StatsdError
impl From<MetricError> for StatsdError
Source§fn from(source: MetricError) -> Self
fn from(source: MetricError) -> Self
Converts to this type from the input type.
Source§impl From<SetRecorderError<StatsdRecorder>> for StatsdError
impl From<SetRecorderError<StatsdRecorder>> for StatsdError
Source§fn from(source: SetRecorderError<StatsdRecorder>) -> Self
fn from(source: SetRecorderError<StatsdRecorder>) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for StatsdError
impl !RefUnwindSafe for StatsdError
impl Send for StatsdError
impl Sync for StatsdError
impl Unpin for StatsdError
impl !UnwindSafe for StatsdError
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