Module opentelemetry_sdk::trace
source · 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 span processor configuration. Use
BatchConfigBuilder
to configure your own instance ofBatchConfig
. - A builder for creating
BatchConfig
instances. - A
SpanProcessor
that asynchronously buffers finished spans and reports them at a preconfigured interval. - A builder for creating
BatchSpanProcessor
instances. - Builder for provider attributes.
- Tracer configuration
- Sampler that fetches the sampling configuration from remotes.
- Builder for
JaegerRemoteSampler
. See Sampler::jaeger_remote for details. - Default
IdGenerator
implementation. - A SpanProcessor that passes finished spans to the configured
SpanExporter
, as soon as they are finished, without any batching. This is typically useful for debugging and testing. For scenarios requiring higher performance/throughput, consider using BatchSpanProcessor. - Single operation within a trace.
- Stores span events along with dropped count.
- Span limit configuration to keep attributes, events and links to a span in a reasonable number.
- Stores span links along with dropped count.
Tracer
implementation to create and manage spans- Creator and registry of named
Tracer
instances.
Enums§
- Default Sampling options
Traits§
- Interface for generating IDs
- 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. 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.
Functions§
- config
Deprecated Default trace configuration