Skip to main content

Crate zerodds_observability_otlp

Crate zerodds_observability_otlp 

Source
Expand description

OTLP/HTTP/JSON exporter for ZeroDDS telemetry.

Crate zerodds-observability-otlp. Safety classification: STANDARD.

Spec: docs/specs/zerodds-observability-otlp-1.0.md. Layer position: Layer 4 — core services (consumer path for foundation::tracing::{Span, Histogram} + foundation::observability::Event).

§What is exported?

Three OTLP endpoints are served:

  • /v1/traces — spans from [foundation::tracing::Span].
  • /v1/metrics — histograms from [foundation::tracing::Histogram].
  • /v1/logs — events from [foundation::observability::Event].

We use the OTLP/HTTP/JSON format per the OpenTelemetry spec v1.4 (https://github.com/open-telemetry/opentelemetry-proto/blob/v1.4.0/ docs/specification.md#otlphttp). JSON is officially supported and needs no Protobuf codegen pipeline — perfect for pure Rust without prost/tonic.

Per tick all buffered spans/histograms/events are POSTed in one batch request.

§Default endpoints

By default a local OTel collector runs on http://127.0.0.1:4318/v1/traces etc. — see examples/otel/jaeger-compose.yml for a local stack.

Structs§

OtlpConfig
Configuration for the exporter.
OtlpExporter
Exporter handle. Buffers spans/histograms/events and flushes them via POST to the OTel collector.

Enums§

ExportError
Error during export.

Constants§

DEFAULT_OTLP_HOST
Defaults — OTel collector on localhost (Jaeger compose).
DEFAULT_OTLP_PORT
Default OTLP/HTTP port (OTel spec).