ErrorReporter

Trait ErrorReporter 

Source
pub trait ErrorReporter: Send + Sync {
    // Required method
    fn capture(&self, error: &Error) -> Result<()>;

    // Provided method
    fn capture_message(
        &self,
        message: impl Into<Cow<'static, str>>,
    ) -> Result<()> { ... }
}
Expand description

Reports non-fatal errors to an observability backend.

Required Methods§

Source

fn capture(&self, error: &Error) -> Result<()>

Capture the provided error for later inspection.

Provided Methods§

Source

fn capture_message(&self, message: impl Into<Cow<'static, str>>) -> Result<()>

Convenience helper to capture a simple message.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§