Skip to main content

Crate sz_orm_tracing

Crate sz_orm_tracing 

Source
Expand description

§SZ-ORM Tracing — Distributed tracing

Provides Span/Tracer abstractions for distributed tracing, with OTLP exporter reporting support, for collection and visualization of cross-service call chains.

§Main types

  • Span — single trace segment
  • Tracer — tracer and exporter

§Sampling and context propagation (sampling module)

Re-exports§

pub use sampling::AlwaysOffSampler;
pub use sampling::AlwaysOnSampler;
pub use sampling::Baggage;
pub use sampling::BaggagePropagator;
pub use sampling::BatchConfig;
pub use sampling::BatchSpanExporter;
pub use sampling::ParentBasedSampler;
pub use sampling::Sampler;
pub use sampling::SamplingDecision;
pub use sampling::TraceIdRatioSampler;

Modules§

sampling
采样策略与 Baggage 传播

Structs§

Alert
Alert event, produced by SaturationGauge / SlaMonitor and other components when an anomaly is detected, and dispatched downstream (logs, webhooks, etc.) via AlertHook.
ErrorBudget
Error budget, based on the SLO target and a sliding time window.
ErrorRateCounter
Error rate counter, based on a sliding time window for error rate statistics.
InMemoryAlertHook
In-memory alert hook (not a real webhook): stores alerts in memory without any network sends.
LatencyHistogram
Latency percentile histogram.
LogAlertHook
A simple implementation that writes alerts to the standard error stream.
OtelTracer
A compatibility wrapper that exposes the same Tracer interface as the OpenTelemetry SDK but is implemented internally by delegating every call to a SzTracer.
SaturationGauge
Saturation alert gauge.
SlaMonitor
SLA monitor, aggregates latency and error statistics by operation name, and generates SlaReport.
SlaReport
SLA monitoring report snapshot, generated by SlaMonitor::report.
Span
SpanLog
SzTracer

Enums§

AlertLevel
Alert level.
TracingError

Traits§

AlertHook
Alert dispatch hook. Implementations can write alerts to logs, send them to a webhook, push them to IM, etc.
Tracer