pub trait ExceptionReporter: Send + Sync {
// Required method
fn report<'life0, 'life1, 'async_trait>(
&'life0 self,
batch: &'life1 ExceptionBatch,
) -> Pin<Box<dyn Future<Output = CollectorResult<ReportResult>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
// Provided method
fn check_available<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = bool> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait { ... }
}Expand description
异常上报器 trait。
定义异常批次上报的统一接口。不同的上报路径 (GitHub Issue、自研平台)实现此 trait。
Required Methods§
Sourcefn report<'life0, 'life1, 'async_trait>(
&'life0 self,
batch: &'life1 ExceptionBatch,
) -> Pin<Box<dyn Future<Output = CollectorResult<ReportResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn report<'life0, 'life1, 'async_trait>(
&'life0 self,
batch: &'life1 ExceptionBatch,
) -> Pin<Box<dyn Future<Output = CollectorResult<ReportResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Provided Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".