ootel

package module
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2024 License: MIT Imports: 14 Imported by: 0

README

ootel

ootel is an "opinionated" opentelemetry initializer.

Currently the only supported exporters are OTLP gRPC (traces) and Prometheus (metrics)

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMetricConfig

func NewMetricConfig(enabled bool, serverPort int) *metricConfig

func NewTraceConfig

func NewTraceConfig(enabled bool, sampleRate float64, serviceName, serviceVersion string) *traceConfig

Types

type OotelClient

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

func NewOotelClient

func NewOotelClient(options ...OotelClientOption) *OotelClient

func (*OotelClient) Init

func (oc *OotelClient) Init(ctx context.Context) (func(context.Context) error, error)

type OotelClientOption

type OotelClientOption func(*OotelClient)

func WithMetricConfig

func WithMetricConfig(mc *metricConfig) OotelClientOption

func WithTraceConfig

func WithTraceConfig(tc *traceConfig) OotelClientOption

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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