Search and commands

↑ ↓ to select · Enter to open · Esc to close

Type to search packages.

goconv

v1.47.0
go.opentelemetry.io/otel/semconv/v1.32.0/goconv

Documentation

pkg.go.dev ↗

Table of contents

↓ to select · Enter to jump· Shift+Enter for source

60 matches

Top ↑

Package goconv provides types and functionality for OpenTelemetry semantic conventions in the "go" namespace.

Types

ConfigGogc

type ConfigGogc struct {
	metric.Int64ObservableUpDownCounter
}

ConfigGogc is an instrument used to record metric values conforming to the "go.config.gogc" semantic conventions. It represents the heap size target percentage configured by the user, otherwise 100.

NewConfigGogc

func NewConfigGogc(
	m metric.Meter,
	opt ...metric.Int64ObservableUpDownCounterOption,
) (ConfigGogc, error)

NewConfigGogc returns a new ConfigGogc instrument.

ConfigGogc.Description

func (ConfigGogc) Description() string

Description returns the semantic convention description of the instrument

ConfigGogc.Inst

func (m ConfigGogc) Inst() metric.Int64ObservableUpDownCounter

Inst returns the underlying metric instrument.

ConfigGogc.Name

func (ConfigGogc) Name() string

Name returns the semantic convention name of the instrument.

ConfigGogc.Unit

func (ConfigGogc) Unit() string

Unit returns the semantic convention unit of the instrument

GoroutineCount

type GoroutineCount struct {
	metric.Int64ObservableUpDownCounter
}

GoroutineCount is an instrument used to record metric values conforming to the "go.goroutine.count" semantic conventions. It represents the count of live goroutines.

NewGoroutineCount

func NewGoroutineCount(
	m metric.Meter,
	opt ...metric.Int64ObservableUpDownCounterOption,
) (GoroutineCount, error)

NewGoroutineCount returns a new GoroutineCount instrument.

GoroutineCount.Description

func (GoroutineCount) Description() string

Description returns the semantic convention description of the instrument

GoroutineCount.Inst

func (m GoroutineCount) Inst() metric.Int64ObservableUpDownCounter

Inst returns the underlying metric instrument.

GoroutineCount.Name

func (GoroutineCount) Name() string

Name returns the semantic convention name of the instrument.

GoroutineCount.Unit

func (GoroutineCount) Unit() string

Unit returns the semantic convention unit of the instrument

MemoryAllocated

type MemoryAllocated struct {
	metric.Int64ObservableCounter
}

MemoryAllocated is an instrument used to record metric values conforming to the "go.memory.allocated" semantic conventions. It represents the memory allocated to the heap by the application.

NewMemoryAllocated

func NewMemoryAllocated(
	m metric.Meter,
	opt ...metric.Int64ObservableCounterOption,
) (MemoryAllocated, error)

NewMemoryAllocated returns a new MemoryAllocated instrument.

MemoryAllocated.Description

func (MemoryAllocated) Description() string

Description returns the semantic convention description of the instrument

MemoryAllocated.Inst

func (m MemoryAllocated) Inst() metric.Int64ObservableCounter

Inst returns the underlying metric instrument.

MemoryAllocated.Name

func (MemoryAllocated) Name() string

Name returns the semantic convention name of the instrument.

MemoryAllocated.Unit

func (MemoryAllocated) Unit() string

Unit returns the semantic convention unit of the instrument

MemoryAllocations

type MemoryAllocations struct {
	metric.Int64ObservableCounter
}

MemoryAllocations is an instrument used to record metric values conforming to the "go.memory.allocations" semantic conventions. It represents the count of allocations to the heap by the application.

NewMemoryAllocations

func NewMemoryAllocations(
	m metric.Meter,
	opt ...metric.Int64ObservableCounterOption,
) (MemoryAllocations, error)

NewMemoryAllocations returns a new MemoryAllocations instrument.

MemoryAllocations.Description

func (MemoryAllocations) Description() string

Description returns the semantic convention description of the instrument

MemoryAllocations.Inst

func (m MemoryAllocations) Inst() metric.Int64ObservableCounter

Inst returns the underlying metric instrument.

MemoryAllocations.Name

func (MemoryAllocations) Name() string

Name returns the semantic convention name of the instrument.

MemoryAllocations.Unit

func (MemoryAllocations) Unit() string

Unit returns the semantic convention unit of the instrument

MemoryGCGoal

type MemoryGCGoal struct {
	metric.Int64ObservableUpDownCounter
}

MemoryGCGoal is an instrument used to record metric values conforming to the "go.memory.gc.goal" semantic conventions. It represents the heap size target for the end of the GC cycle.

NewMemoryGCGoal

func NewMemoryGCGoal(
	m metric.Meter,
	opt ...metric.Int64ObservableUpDownCounterOption,
) (MemoryGCGoal, error)

NewMemoryGCGoal returns a new MemoryGCGoal instrument.

MemoryGCGoal.Description

func (MemoryGCGoal) Description() string

Description returns the semantic convention description of the instrument

MemoryGCGoal.Inst

func (m MemoryGCGoal) Inst() metric.Int64ObservableUpDownCounter

Inst returns the underlying metric instrument.

MemoryGCGoal.Name

func (MemoryGCGoal) Name() string

Name returns the semantic convention name of the instrument.

MemoryGCGoal.Unit

func (MemoryGCGoal) Unit() string

Unit returns the semantic convention unit of the instrument

MemoryLimit

type MemoryLimit struct {
	metric.Int64ObservableUpDownCounter
}

MemoryLimit is an instrument used to record metric values conforming to the "go.memory.limit" semantic conventions. It represents the go runtime memory limit configured by the user, if a limit exists.

NewMemoryLimit

func NewMemoryLimit(
	m metric.Meter,
	opt ...metric.Int64ObservableUpDownCounterOption,
) (MemoryLimit, error)

NewMemoryLimit returns a new MemoryLimit instrument.

MemoryLimit.Description

func (MemoryLimit) Description() string

Description returns the semantic convention description of the instrument

MemoryLimit.Inst

func (m MemoryLimit) Inst() metric.Int64ObservableUpDownCounter

Inst returns the underlying metric instrument.

MemoryLimit.Name

func (MemoryLimit) Name() string

Name returns the semantic convention name of the instrument.

MemoryLimit.Unit

func (MemoryLimit) Unit() string

Unit returns the semantic convention unit of the instrument

MemoryTypeAttr

type MemoryTypeAttr string

MemoryTypeAttr is an attribute conforming to the go.memory.type semantic conventions. It represents the type of memory.

MemoryTypeStack (2 declarations)

var (
	// MemoryTypeStack is the memory allocated from the heap that is reserved for
	// stack space, whether or not it is currently in-use.
	MemoryTypeStack MemoryTypeAttr = "stack"
	// MemoryTypeOther is the memory used by the Go runtime, excluding other
	// categories of memory usage described in this enumeration.
	MemoryTypeOther MemoryTypeAttr = "other"
)

MemoryUsed

type MemoryUsed struct {
	metric.Int64ObservableCounter
}

MemoryUsed is an instrument used to record metric values conforming to the "go.memory.used" semantic conventions. It represents the memory used by the Go runtime.

NewMemoryUsed

func NewMemoryUsed(
	m metric.Meter,
	opt ...metric.Int64ObservableCounterOption,
) (MemoryUsed, error)

NewMemoryUsed returns a new MemoryUsed instrument.

MemoryUsed.AttrMemoryType

func (MemoryUsed) AttrMemoryType(val MemoryTypeAttr) attribute.KeyValue

AttrMemoryType returns an optional attribute for the "go.memory.type" semantic convention. It represents the type of memory.

MemoryUsed.Description

func (MemoryUsed) Description() string

Description returns the semantic convention description of the instrument

MemoryUsed.Inst

func (m MemoryUsed) Inst() metric.Int64ObservableCounter

Inst returns the underlying metric instrument.

MemoryUsed.Name

func (MemoryUsed) Name() string

Name returns the semantic convention name of the instrument.

MemoryUsed.Unit

func (MemoryUsed) Unit() string

Unit returns the semantic convention unit of the instrument

ProcessorLimit

type ProcessorLimit struct {
	metric.Int64ObservableUpDownCounter
}

ProcessorLimit is an instrument used to record metric values conforming to the "go.processor.limit" semantic conventions. It represents the number of OS threads that can execute user-level Go code simultaneously.

NewProcessorLimit

func NewProcessorLimit(
	m metric.Meter,
	opt ...metric.Int64ObservableUpDownCounterOption,
) (ProcessorLimit, error)

NewProcessorLimit returns a new ProcessorLimit instrument.

ProcessorLimit.Description

func (ProcessorLimit) Description() string

Description returns the semantic convention description of the instrument

ProcessorLimit.Inst

func (m ProcessorLimit) Inst() metric.Int64ObservableUpDownCounter

Inst returns the underlying metric instrument.

ProcessorLimit.Name

func (ProcessorLimit) Name() string

Name returns the semantic convention name of the instrument.

ProcessorLimit.Unit

func (ProcessorLimit) Unit() string

Unit returns the semantic convention unit of the instrument

ScheduleDuration

type ScheduleDuration struct {
	metric.Float64Histogram
}

ScheduleDuration is an instrument used to record metric values conforming to the "go.schedule.duration" semantic conventions. It represents the time goroutines have spent in the scheduler in a runnable state before actually running.

NewScheduleDuration

func NewScheduleDuration(
	m metric.Meter,
	opt ...metric.Float64HistogramOption,
) (ScheduleDuration, error)

NewScheduleDuration returns a new ScheduleDuration instrument.

ScheduleDuration.Description

func (ScheduleDuration) Description() string

Description returns the semantic convention description of the instrument

ScheduleDuration.Inst

func (m ScheduleDuration) Inst() metric.Float64Histogram

Inst returns the underlying metric instrument.

ScheduleDuration.Name

func (ScheduleDuration) Name() string

Name returns the semantic convention name of the instrument.

ScheduleDuration.Record

func (m ScheduleDuration) Record(ctx context.Context, val float64, attrs ...attribute.KeyValue)

Record records val to the current distribution.

Computed from `/sched/latencies:seconds`. Bucket boundaries are provided by the runtime, and are subject to change.

ScheduleDuration.Unit

func (ScheduleDuration) Unit() string

Unit returns the semantic convention unit of the instrument

Dependency graph