otlp

package module
v0.0.7 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2024 License: MIT Imports: 16 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GlobalMeter added in v0.0.6

func GlobalMeter() metric.Meter

GlobalMeter returns the global meter.

func GlobalTracer added in v0.0.6

func GlobalTracer() trace.Tracer

GlobalTracer returns the global tracer.

func InitGlobalMeter added in v0.0.6

func InitGlobalMeter(opts ...InitOption) (*sdkmetric.MeterProvider, error)

InitGlobalMeter initializes the global meter.

func InitGlobalTracer

func InitGlobalTracer(opts ...InitOption) (*sdktrace.TracerProvider, error)

InitGlobalTracer initializes the global tracer.

func NewFloat64Counter added in v0.0.6

func NewFloat64Counter(name string, opts ...metric.Float64CounterOption) metric.Float64Counter

NewFloat64Counter creates a new float64 counter.

func NewFloat64Histogram added in v0.0.6

func NewFloat64Histogram(name string, opts ...metric.Float64HistogramOption) metric.Float64Histogram

NewFloat64Histogram creates a new float64 histogram.

func NewFloat64ObservableCounter added in v0.0.6

func NewFloat64ObservableCounter(name string, opts ...metric.Float64ObservableCounterOption) metric.Float64ObservableCounter

NewFloat64ObservableCounter creates a new float64 observable counter.

func NewFloat64ObservableGauge added in v0.0.6

func NewFloat64ObservableGauge(name string, opts ...metric.Float64ObservableGaugeOption) metric.Float64ObservableGauge

NewFloat64ObservableGauge creates a new float64 observable gauge.

func NewFloat64ObservableUpDownCounter added in v0.0.6

func NewFloat64ObservableUpDownCounter(name string, opts ...metric.Float64ObservableUpDownCounterOption) metric.Float64ObservableUpDownCounter

NewFloat64ObservableUpDownCounter creates a new float64 observable up down counter.

func NewFloat64UpDownCounter added in v0.0.6

func NewFloat64UpDownCounter(name string, opts ...metric.Float64UpDownCounterOption) metric.Float64UpDownCounter

NewFloat64UpDownCounter creates a new float64 up down counter.

func NewInt64Counter added in v0.0.6

func NewInt64Counter(name string, opts ...metric.Int64CounterOption) metric.Int64Counter

NewInt64Counter creates a new int64 counter.

func NewInt64Histogram added in v0.0.6

func NewInt64Histogram(name string, opts ...metric.Int64HistogramOption) metric.Int64Histogram

NewInt64Histogram creates a new int64 histogram.

func NewInt64ObservableCounter added in v0.0.6

func NewInt64ObservableCounter(name string, opts ...metric.Int64ObservableCounterOption) metric.Int64ObservableCounter

NewInt64ObservableCounter creates a new int64 observable counter.

func NewInt64ObservableGauge added in v0.0.6

func NewInt64ObservableGauge(name string, opts ...metric.Int64ObservableGaugeOption) metric.Int64ObservableGauge

NewInt64ObservableGauge creates a new int64 observable gauge.

func NewInt64ObservableUpDownCounter added in v0.0.6

func NewInt64ObservableUpDownCounter(name string, opts ...metric.Int64ObservableUpDownCounterOption) metric.Int64ObservableUpDownCounter

NewInt64ObservableUpDownCounter creates a new int64 observable up down counter.

func NewInt64UpDownCounter added in v0.0.6

func NewInt64UpDownCounter(name string, opts ...metric.Int64UpDownCounterOption) metric.Int64UpDownCounter

NewInt64UpDownCounter creates a new int64 up down counter.

func SetGlobalMeter added in v0.0.6

func SetGlobalMeter(meter metric.Meter)

SetGlobalMeter sets the global meter.

func SetGlobalTracer added in v0.0.6

func SetGlobalTracer(tracer trace.Tracer)

SetGlobalTracer sets the global tracer.

func Start

func Start(ctx context.Context, spanName string, opts ...trace.SpanStartOption) (context.Context, trace.Span)

Start starts a new span.

Types

type InitOption

type InitOption func(*option)

func WithContext added in v0.0.6

func WithContext(ctx context.Context) InitOption

WithContext sets the context

func WithEndPoint

func WithEndPoint(endpoint string) InitOption

WithEndPoint sets the endpoint.

func WithErrorHandler added in v0.0.4

func WithErrorHandler(handler otel.ErrorHandlerFunc) InitOption

WithErrorHandler sets the error handler.

func WithInSecure

func WithInSecure() InitOption

WithInSecure sets the gRPC inscure mode

func WithServiceName

func WithServiceName(serviceName string) InitOption

WithServiceName sets the service name.

type ShutdownFunc added in v0.0.6

type ShutdownFunc func(ctx context.Context) error

func (ShutdownFunc) Shutdown added in v0.0.6

func (f ShutdownFunc) Shutdown(ctx context.Context) error

type ShutdownHandler added in v0.0.6

type ShutdownHandler interface {
	Shutdown(ctx context.Context) error
}

func InitExporter added in v0.0.6

func InitExporter(opts ...InitOption) (ShutdownHandler, error)

InitExporter initializes the global tracer and meter.

Directories

Path Synopsis
examples

Jump to

Keyboard shortcuts

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