telemetry

package
v0.0.0-...-0451d2a Latest Latest
Warning

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

Go to latest
Published: May 12, 2023 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Counter

type Counter interface {
	Add(ctx context.Context, value int64, opts ...CounterAttributes)
}

type CounterAttribute

type CounterAttribute struct {
	Key   string
	Value string
}

type CounterAttributes

type CounterAttributes []CounterAttribute

type CounterOption

type CounterOption func(*CounterOpts)

func WithDescription

func WithDescription(description string) CounterOption

func WithUnit

func WithUnit(unit string) CounterOption

type CounterOpts

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

func (*CounterOpts) Apply

func (o *CounterOpts) Apply(opts ...CounterOption)

func (*CounterOpts) Description

func (o *CounterOpts) Description() string

func (*CounterOpts) Unit

func (o *CounterOpts) Unit() string

type Meter

type Meter interface {
	Int64Counter(name string, opts ...CounterOption) (Counter, error)
	Int64UpDownCounter(name string, opts ...CounterOption) (Counter, error)
}

type NoopCounter

type NoopCounter struct{}

func (*NoopCounter) Add

func (c *NoopCounter) Add(ctx context.Context, value int64, opts ...CounterAttributes)

type NoopMeter

type NoopMeter struct{}

func (*NoopMeter) Int64Counter

func (m *NoopMeter) Int64Counter(name string, opts ...CounterOption) (Counter, error)

func (*NoopMeter) Int64UpDownCounter

func (m *NoopMeter) Int64UpDownCounter(name string, opts ...CounterOption) (Counter, error)

type Span

type Span interface {
	Error(err error)
	End() error
}

type SpanOption

type SpanOption func(Span)

type Tracer

type Tracer interface {
	StartSpan(ctx context.Context, name string, opts ...SpanOption) (newCtx context.Context, span Span)
	Shutdown(context.Context) error
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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