pub struct OtlpHttpExporter { /* private fields */ }Expand description
An SpanExporter that POSTs OTLP/HTTP JSON spans to a collector.
Construct it with the collector’s base URL (e.g.
http://otel-collector:4318); the exporter appends the standard
/v1/traces path. A pooled HTTP client is reused across exports.
Must be constructed within a Tokio runtime (it captures the runtime handle to spawn background sends). Outside a runtime, export is a no-op rather than a panic, telemetry is best-effort and never affects the caller.
Implementations§
Trait Implementations§
Source§impl Clone for OtlpHttpExporter
impl Clone for OtlpHttpExporter
Source§fn clone(&self) -> OtlpHttpExporter
fn clone(&self) -> OtlpHttpExporter
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for OtlpHttpExporter
impl Debug for OtlpHttpExporter
Source§impl SpanExporter for OtlpHttpExporter
impl SpanExporter for OtlpHttpExporter
Source§fn export(&self, payload: Value)
fn export(&self, payload: Value)
Hands off a finished OTLP
ResourceSpans payload (from
resource_spans) for background delivery.
Returns immediately; delivery is best-effort.Auto Trait Implementations§
impl !RefUnwindSafe for OtlpHttpExporter
impl !UnwindSafe for OtlpHttpExporter
impl Freeze for OtlpHttpExporter
impl Send for OtlpHttpExporter
impl Sync for OtlpHttpExporter
impl Unpin for OtlpHttpExporter
impl UnsafeUnpin for OtlpHttpExporter
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more