Documentation ¶
Index ¶
Constants ¶
View Source
const (
// ForceTracingBaggageKey is a request header name that forces tracing sampling.
ForceTracingBaggageKey = "X-Thanos-Force-Tracing"
)
Variables ¶
This section is empty.
Functions ¶
func ContextWithTracer ¶
ContextWithTracer returns a new `context.Context` that holds a reference to given opentracing.Tracer.
func DoWithSpan ¶
func DoWithSpan(ctx context.Context, operationName string, doFn func(context.Context, Span), opts ...opentracing.StartSpanOption)
DoWithSpan executes function doFn inside new span with `operationName` name and hooking as child to a span found within given context if any. It uses opentracing.Tracer propagated in context. If no found, it uses noop tracer notification.
Types ¶
type Span ¶
type Span = opentracing.Span
func StartSpan ¶
func StartSpan(ctx context.Context, operationName string, opts ...opentracing.StartSpanOption) (Span, context.Context)
StartSpan starts and returns span with `operationName` and hooking as child to a span found within given context if any. It uses opentracing.Tracer propagated in context. If no found, it uses noop tracer without notification.
Click to show internal directories.
Click to hide internal directories.