Trait opentelemetry::global::GenericTracerProvider
source · [−]pub trait GenericTracerProvider: Debug + 'static {
fn tracer_boxed(
&self,
name: &'static str,
version: Option<&'static str>
) -> Box<dyn GenericTracer + Send + Sync>;
fn force_flush(&self) -> Vec<TraceResult<()>>;
}
Expand description
Allows a specific TracerProvider
to be used generically by the
GlobalTracerProvider
by mirroring the interface and boxing the return types.
Required Methods
sourcefn tracer_boxed(
&self,
name: &'static str,
version: Option<&'static str>
) -> Box<dyn GenericTracer + Send + Sync>
fn tracer_boxed(
&self,
name: &'static str,
version: Option<&'static str>
) -> Box<dyn GenericTracer + Send + Sync>
Creates a named tracer instance that is a trait object through the underlying TracerProvider
.
sourcefn force_flush(&self) -> Vec<TraceResult<()>>
fn force_flush(&self) -> Vec<TraceResult<()>>
Force flush all remaining spans in span processors and return results.