Trait opentelemetry::sdk::trace::TrySend
source · pub trait TrySend: Sync + Send {
// Required method
fn try_send(&self, item: BatchMessage) -> Result<(), TraceError>;
}
Available on crate feature
trace
only.Expand description
TrySend is an abstraction of sender that is capable to send BatchMessage with reference.
Required Methods§
sourcefn try_send(&self, item: BatchMessage) -> Result<(), TraceError>
fn try_send(&self, item: BatchMessage) -> Result<(), TraceError>
Try to send one batch message to worker thread.
It can fail because either the receiver has closed or the buffer is full.
Implementations on Foreign Types§
source§impl TrySend for Sender<BatchMessage>
Available on crate features rt-tokio
or rt-tokio-current-thread
only.
impl TrySend for Sender<BatchMessage>
Available on crate features
rt-tokio
or rt-tokio-current-thread
only.fn try_send(&self, item: BatchMessage) -> Result<(), TraceError>
source§impl TrySend for Sender<BatchMessage>
Available on crate feature rt-async-std
only.
impl TrySend for Sender<BatchMessage>
Available on crate feature
rt-async-std
only.