traces

package
v0.0.45 Latest Latest
Warning

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

Go to latest
Published: May 21, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Overview

Package traces provides helper functions for tracing with OpenTelemetry SDK.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitTracerProvider

func InitTracerProvider(log logging.Logger, otelCollectorAddress string, dialTimeout, exportInterval time.Duration) (func(context.Context), error)

InitTracerProvider configures a global tracer provider and dials to the OTEL Collector. Failing in doing so returns an error since service actively export their traces and require the Collector to be up. Returns a shutdown function that should be called at the end of the program to flush all in-momory traces.

func SetAndRecordError

func SetAndRecordError(span trace.Span, err error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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