Struct opentelemetry::sdk::trace::SimpleSpanProcessor
source · [−]pub struct SimpleSpanProcessor { /* private fields */ }
Available on crate feature
trace
only.Expand description
A SpanProcessor
that exports synchronously when spans are finished.
Examples
Note that the simple processor exports synchronously every time a span is ended. If you find this limiting, consider the batch processor instead.
Trait Implementations
sourceimpl Debug for SimpleSpanProcessor
impl Debug for SimpleSpanProcessor
sourceimpl SpanProcessor for SimpleSpanProcessor
impl SpanProcessor for SimpleSpanProcessor
sourcefn on_start(&self, _span: &mut Span, _cx: &Context)
fn on_start(&self, _span: &mut Span, _cx: &Context)
on_start
is called when a Span
is started. This method is called
synchronously on the thread that started the span, therefore it should
not block or throw exceptions. Read more
sourcefn on_end(&self, span: SpanData)
fn on_end(&self, span: SpanData)
on_end
is called after a Span
is ended (i.e., the end timestamp is
already set). This method is called synchronously within the Span::end
API, therefore it should not block or throw an exception. Read more
sourcefn force_flush(&self) -> Result<(), TraceError>
fn force_flush(&self) -> Result<(), TraceError>
Force the spans lying in the cache to be exported.
Auto Trait Implementations
impl RefUnwindSafe for SimpleSpanProcessor
impl Send for SimpleSpanProcessor
impl Sync for SimpleSpanProcessor
impl Unpin for SimpleSpanProcessor
impl UnwindSafe for SimpleSpanProcessor
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more