katatrace

package
v0.0.0-...-4ae9317 Latest Latest
Warning

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

Go to latest
Published: Oct 17, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddTags

func AddTags(span otelTrace.Span, keyValues ...interface{})

AddTag adds additional key-value pairs to a tracing span. This can be used to provide dynamic tags that are determined at runtime and tags with a non-string value. Must have an even number of keyValues with keys being strings.

func CreateTracer

func CreateTracer(name string, config *JaegerConfig) (*sdktrace.TracerProvider, error)

CreateTracer create a tracer

func SetTracing

func SetTracing(isTracing bool)

SetTracing turns tracing on or off. Called by the configuration.

func StopTracing

func StopTracing(ctx context.Context)

StopTracing ends all tracing, reporting the spans to the collector.

func Trace

func Trace(parent context.Context, logger *logrus.Entry, name string, tags ...map[string]string) (otelTrace.Span, context.Context)

Trace creates a new tracing span based on the specified name and parent context. It also accepts a logger to record nil context errors and a map of tracing tags. Tracing tag keys and values are strings.

Types

type JaegerConfig

type JaegerConfig struct {
	JaegerEndpoint string
	JaegerUser     string
	JaegerPassword string
}

JaegerConfig defines necessary Jaeger config for exporting traces.

Jump to

Keyboard shortcuts

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