migration

package
v0.32.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 2, 2023 License: Apache-2.0 Imports: 13 Imported by: 3

Documentation

Index

Constants

View Source
const ForceTracingAttributeKey = "thanos.force_tracing"

ForceTracingAttributeKey is used to signalize a span should be traced.

Variables

This section is empty.

Functions

func Bridge

func Bridge(tp *tracesdk.TracerProvider, l log.Logger) (opentracing.Tracer, io.Closer)

Bridge is a method to facilitate migration from OpenTracing (OT) to OpenTelemetry (OTEL). It pairs an OTEL tracer with a so-called bridge tracer, which satisfies the OT Tracer interface. This makes it possible for OT instrumentation to work with an OTEL tracer.

NOTE: After instrumentation migration is finished, this bridge should be removed.

func GetTraceIDFromBridgeSpan

func GetTraceIDFromBridgeSpan(span opentracing.Span) (string, bool)

func SamplerWithOverride

func SamplerWithOverride(baseSampler tracesdk.Sampler, overrideKey attribute.Key) tracesdk.Sampler

SamplerWithOverride creates a new sampler with the capability to override the sampling decision, if the span includes an attribute with the specified key. Otherwise the sampler delegates the decision to the wrapped base sampler. This is primarily used to enable forced tracing in Thanos components. Implements go.opentelemetry.io/otel/sdk/trace.Sampler interface.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL