tracing

package
v0.26.2 Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2024 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitTracer

func InitTracer(opts ...otlptracehttp.Option) error

func InitTracerWithHoneycomb

func InitTracerWithHoneycomb(key string, opts ...otlptracehttp.Option) error

func LogRecoverToExit

func LogRecoverToExit(ctx *context.Context, loc string)

LogRecoverToExit Recovers from a panic, logs and forwards it sentry and otel, then exits Does nothing when there is no panic.

func LogRecoverToReturn

func LogRecoverToReturn(ctx *context.Context, loc string)

LogRecoverToReturn Recovers from a panic, logs and forwards it sentry and otel, then returns Does nothing when there is no panic.

func ShutdownTracer

func ShutdownTracer()

nolint: contextcheck // deliberate use of local context to avoid getting tangled up in any existing timeouts or cancels

func Tracer

func Tracer() trace.Tracer

Types

type UserAgentSampler

type UserAgentSampler struct {
	// contains filtered or unexported fields
}

func NewUserAgentSampler

func NewUserAgentSampler(userAgent string, sampleRate int) *UserAgentSampler

func (*UserAgentSampler) Description

func (h *UserAgentSampler) Description() string

Description returns information describing the Sampler.

func (*UserAgentSampler) ShouldSample

ShouldSample returns a SamplingResult based on a decision made from the passed parameters.

Jump to

Keyboard shortcuts

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