Available on crate feature
trace
only.Expand description
§OpenTelemetry Trace SDK
The tracing SDK consist of a few main structs:
- The
Tracer
struct which performs all tracing operations. - The
Span
struct with is a mutable object storing information about the current operation execution. - The
TracerProvider
struct which configures and producesTracer
s.
Structs§
- Batch
Config - Batch span processor configuration
- Batch
Span Processor - A
SpanProcessor
that asynchronously buffers finished spans and reports them at a preconfigured interval. - Batch
Span Processor Builder - A builder for creating
BatchSpanProcessor
instances. - Builder
- Builder for provider attributes.
- Config
- Tracer configuration
- Evicted
Hash Map - A hash map with a capped number of attributes that retains the most recently set entries.
- Evicted
Queue - This queue maintains an ordered list of elements, and a count of dropped elements. Elements are removed from the queue in a first in first out fashion.
- IdGenerator
- Default
crate::trace::IdGenerator
implementation. Generates Trace and Span ids using a random number generator. - Sampling
Result - The result of sampling logic for a given
Span
. - Simple
Span Processor - A
SpanProcessor
that exports synchronously when spans are finished. - Span
- Single operation within a trace.
- Span
Limits - Span limit configuration to keep attributes, events and links to a span in a reasonable number.
- Tracer
Tracer
implementation to create and manage spans- Tracer
Provider - Creator and registry of named
Tracer
instances. - Xray
IdGenerator - Generates AWS X-Ray compliant Trace and Span ids.
Enums§
- Batch
Message - Messages sent between application thread and batch span processor’s work thread.
- Sampler
- Sampling options
- Sampling
Decision - Decision about whether or not to sample
Traits§
- Should
Sample - The
ShouldSample
interface allows implementations to provide samplers which will return a samplingSamplingResult
based on information that is typically available just before theSpan
was created. - Span
Processor SpanProcessor
is an interface which allows hooks for span start and end method invocations. The span processors are invoked only when is_recording is true.- Trace
Runtime - Trace runtime is an extension to
Runtime
. Currently it provides a channel that used byBatchSpanProcessor
. - TrySend
- TrySend is an abstraction of sender that is capable to send BatchMessage with reference.
Functions§
- config
- Default trace configuration