Skip to main content

TracingBridge

Trait TracingBridge 

Source
pub trait TracingBridge: Send + Sync {
    // Required methods
    fn begin_span(
        &self,
        name: &str,
        kind: ObservabilitySpanKind,
        run_id: Uuid,
        attributes: &HashMap<String, Value>,
    ) -> BoxFuture<'_, Uuid>;
    fn end_span(
        &self,
        span_id: Uuid,
        outcome: SpanOutcome,
        attributes: &HashMap<String, Value>,
    ) -> BoxFuture<'_, ()>;
}
Expand description

Trait for bridging observability events to a tracing backend.

Required Methods§

Source

fn begin_span( &self, name: &str, kind: ObservabilitySpanKind, run_id: Uuid, attributes: &HashMap<String, Value>, ) -> BoxFuture<'_, Uuid>

Begins a new span, returning a span identifier.

Source

fn end_span( &self, span_id: Uuid, outcome: SpanOutcome, attributes: &HashMap<String, Value>, ) -> BoxFuture<'_, ()>

Ends a span with the given outcome.

Implementors§