Documentation
¶
Overview ¶
Package processconv provides types and functionality for OpenTelemetry semantic conventions in the "process" namespace.
Index ¶
- type CPUModeAttr
- type CPUTime
- type CPUUtilization
- func (CPUUtilization) AttrCPUMode(val CPUModeAttr) attribute.KeyValue
- func (CPUUtilization) Description() string
- func (m CPUUtilization) Inst() metric.Int64Gauge
- func (CPUUtilization) Name() string
- func (m CPUUtilization) Record(ctx context.Context, val int64, attrs ...attribute.KeyValue)
- func (CPUUtilization) Unit() string
- type ContextSwitchTypeAttr
- type ContextSwitches
- func (m ContextSwitches) Add(ctx context.Context, incr int64, attrs ...attribute.KeyValue)
- func (ContextSwitches) AttrContextSwitchType(val ContextSwitchTypeAttr) attribute.KeyValue
- func (ContextSwitches) Description() string
- func (m ContextSwitches) Inst() metric.Int64Counter
- func (ContextSwitches) Name() string
- func (ContextSwitches) Unit() string
- type DiskIO
- type DiskIODirectionAttr
- type MemoryUsage
- type MemoryVirtual
- type NetworkIO
- func (m NetworkIO) Add(ctx context.Context, incr int64, attrs ...attribute.KeyValue)
- func (NetworkIO) AttrNetworkIODirection(val NetworkIODirectionAttr) attribute.KeyValue
- func (NetworkIO) Description() string
- func (m NetworkIO) Inst() metric.Int64Counter
- func (NetworkIO) Name() string
- func (NetworkIO) Unit() string
- type NetworkIODirectionAttr
- type OpenFileDescriptorCount
- func (m OpenFileDescriptorCount) Add(ctx context.Context, incr int64, attrs ...attribute.KeyValue)
- func (OpenFileDescriptorCount) Description() string
- func (m OpenFileDescriptorCount) Inst() metric.Int64UpDownCounter
- func (OpenFileDescriptorCount) Name() string
- func (OpenFileDescriptorCount) Unit() string
- type PagingFaultTypeAttr
- type PagingFaults
- func (m PagingFaults) Add(ctx context.Context, incr int64, attrs ...attribute.KeyValue)
- func (PagingFaults) AttrPagingFaultType(val PagingFaultTypeAttr) attribute.KeyValue
- func (PagingFaults) Description() string
- func (m PagingFaults) Inst() metric.Int64Counter
- func (PagingFaults) Name() string
- func (PagingFaults) Unit() string
- type ThreadCount
- type Uptime
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CPUModeAttr ¶
type CPUModeAttr string
CPUModeAttr is an attribute conforming to the cpu.mode semantic conventions. It represents a process SHOULD be characterized *either* by data points with no `mode` labels, *or only* data points with `mode` labels.
var ( // CPUModeUser is the none. CPUModeUser CPUModeAttr = "user" // CPUModeSystem is the none. CPUModeSystem CPUModeAttr = "system" // CPUModeNice is the none. CPUModeNice CPUModeAttr = "nice" // CPUModeIdle is the none. CPUModeIdle CPUModeAttr = "idle" // CPUModeIOWait is the none. CPUModeIOWait CPUModeAttr = "iowait" // CPUModeInterrupt is the none. CPUModeInterrupt CPUModeAttr = "interrupt" // CPUModeSteal is the none. CPUModeSteal CPUModeAttr = "steal" // CPUModeKernel is the none. CPUModeKernel CPUModeAttr = "kernel" )
type CPUTime ¶
type CPUTime struct {
metric.Float64ObservableCounter
}
CPUTime is an instrument used to record metric values conforming to the "process.cpu.time" semantic conventions. It represents the total CPU seconds broken down by different states.
func NewCPUTime ¶
NewCPUTime returns a new CPUTime instrument.
func (CPUTime) AttrCPUMode ¶
func (CPUTime) AttrCPUMode(val CPUModeAttr) attribute.KeyValue
AttrCPUMode returns an optional attribute for the "cpu.mode" semantic convention. It represents a process SHOULD be characterized *either* by data points with no `mode` labels, *or only* data points with `mode` labels.
func (CPUTime) Description ¶
Description returns the semantic convention description of the instrument
func (CPUTime) Inst ¶
func (m CPUTime) Inst() metric.Float64ObservableCounter
Inst returns the underlying metric instrument.
type CPUUtilization ¶
type CPUUtilization struct {
metric.Int64Gauge
}
CPUUtilization is an instrument used to record metric values conforming to the "process.cpu.utilization" semantic conventions. It represents the difference in process.cpu.time since the last measurement, divided by the elapsed time and number of CPUs available to the process.
func NewCPUUtilization ¶
func NewCPUUtilization( m metric.Meter, opt ...metric.Int64GaugeOption, ) (CPUUtilization, error)
NewCPUUtilization returns a new CPUUtilization instrument.
func (CPUUtilization) AttrCPUMode ¶
func (CPUUtilization) AttrCPUMode(val CPUModeAttr) attribute.KeyValue
AttrCPUMode returns an optional attribute for the "cpu.mode" semantic convention. It represents a process SHOULD be characterized *either* by data points with no `mode` labels, *or only* data points with `mode` labels.
func (CPUUtilization) Description ¶
func (CPUUtilization) Description() string
Description returns the semantic convention description of the instrument
func (CPUUtilization) Inst ¶
func (m CPUUtilization) Inst() metric.Int64Gauge
Inst returns the underlying metric instrument.
func (CPUUtilization) Name ¶
func (CPUUtilization) Name() string
Name returns the semantic convention name of the instrument.
func (CPUUtilization) Record ¶
Record records val to the current distribution.
All additional attrs passed are included in the recorded value.
func (CPUUtilization) Unit ¶
func (CPUUtilization) Unit() string
Unit returns the semantic convention unit of the instrument
type ContextSwitchTypeAttr ¶
type ContextSwitchTypeAttr string
ContextSwitchTypeAttr is an attribute conforming to the process.context_switch_type semantic conventions. It represents the specifies whether the context switches for this data point were voluntary or involuntary.
var ( // ContextSwitchTypeVoluntary is the none. ContextSwitchTypeVoluntary ContextSwitchTypeAttr = "voluntary" // ContextSwitchTypeInvoluntary is the none. ContextSwitchTypeInvoluntary ContextSwitchTypeAttr = "involuntary" )
type ContextSwitches ¶
type ContextSwitches struct {
metric.Int64Counter
}
ContextSwitches is an instrument used to record metric values conforming to the "process.context_switches" semantic conventions. It represents the number of times the process has been context switched.
func NewContextSwitches ¶
func NewContextSwitches( m metric.Meter, opt ...metric.Int64CounterOption, ) (ContextSwitches, error)
NewContextSwitches returns a new ContextSwitches instrument.
func (ContextSwitches) Add ¶
Add adds incr to the existing count.
All additional attrs passed are included in the recorded value.
func (ContextSwitches) AttrContextSwitchType ¶
func (ContextSwitches) AttrContextSwitchType(val ContextSwitchTypeAttr) attribute.KeyValue
AttrContextSwitchType returns an optional attribute for the "process.context_switch_type" semantic convention. It represents the specifies whether the context switches for this data point were voluntary or involuntary.
func (ContextSwitches) Description ¶
func (ContextSwitches) Description() string
Description returns the semantic convention description of the instrument
func (ContextSwitches) Inst ¶
func (m ContextSwitches) Inst() metric.Int64Counter
Inst returns the underlying metric instrument.
func (ContextSwitches) Name ¶
func (ContextSwitches) Name() string
Name returns the semantic convention name of the instrument.
func (ContextSwitches) Unit ¶
func (ContextSwitches) Unit() string
Unit returns the semantic convention unit of the instrument
type DiskIO ¶
type DiskIO struct {
metric.Int64Counter
}
DiskIO is an instrument used to record metric values conforming to the "process.disk.io" semantic conventions. It represents the disk bytes transferred.
func (DiskIO) Add ¶
Add adds incr to the existing count.
All additional attrs passed are included in the recorded value.
func (DiskIO) AttrDiskIODirection ¶
func (DiskIO) AttrDiskIODirection(val DiskIODirectionAttr) attribute.KeyValue
AttrDiskIODirection returns an optional attribute for the "disk.io.direction" semantic convention. It represents the disk IO operation direction.
func (DiskIO) Description ¶
Description returns the semantic convention description of the instrument
func (DiskIO) Inst ¶
func (m DiskIO) Inst() metric.Int64Counter
Inst returns the underlying metric instrument.
type DiskIODirectionAttr ¶
type DiskIODirectionAttr string
DiskIODirectionAttr is an attribute conforming to the disk.io.direction semantic conventions. It represents the disk IO operation direction.
var ( // DiskIODirectionRead is the none. DiskIODirectionRead DiskIODirectionAttr = "read" // DiskIODirectionWrite is the none. DiskIODirectionWrite DiskIODirectionAttr = "write" )
type MemoryUsage ¶
type MemoryUsage struct {
metric.Int64UpDownCounter
}
MemoryUsage is an instrument used to record metric values conforming to the "process.memory.usage" semantic conventions. It represents the amount of physical memory in use.
func NewMemoryUsage ¶
func NewMemoryUsage( m metric.Meter, opt ...metric.Int64UpDownCounterOption, ) (MemoryUsage, error)
NewMemoryUsage returns a new MemoryUsage instrument.
func (MemoryUsage) Description ¶
func (MemoryUsage) Description() string
Description returns the semantic convention description of the instrument
func (MemoryUsage) Inst ¶
func (m MemoryUsage) Inst() metric.Int64UpDownCounter
Inst returns the underlying metric instrument.
func (MemoryUsage) Name ¶
func (MemoryUsage) Name() string
Name returns the semantic convention name of the instrument.
func (MemoryUsage) Unit ¶
func (MemoryUsage) Unit() string
Unit returns the semantic convention unit of the instrument
type MemoryVirtual ¶
type MemoryVirtual struct {
metric.Int64UpDownCounter
}
MemoryVirtual is an instrument used to record metric values conforming to the "process.memory.virtual" semantic conventions. It represents the amount of committed virtual memory.
func NewMemoryVirtual ¶
func NewMemoryVirtual( m metric.Meter, opt ...metric.Int64UpDownCounterOption, ) (MemoryVirtual, error)
NewMemoryVirtual returns a new MemoryVirtual instrument.
func (MemoryVirtual) Description ¶
func (MemoryVirtual) Description() string
Description returns the semantic convention description of the instrument
func (MemoryVirtual) Inst ¶
func (m MemoryVirtual) Inst() metric.Int64UpDownCounter
Inst returns the underlying metric instrument.
func (MemoryVirtual) Name ¶
func (MemoryVirtual) Name() string
Name returns the semantic convention name of the instrument.
func (MemoryVirtual) Unit ¶
func (MemoryVirtual) Unit() string
Unit returns the semantic convention unit of the instrument
type NetworkIO ¶
type NetworkIO struct {
metric.Int64Counter
}
NetworkIO is an instrument used to record metric values conforming to the "process.network.io" semantic conventions. It represents the network bytes transferred.
func NewNetworkIO ¶
NewNetworkIO returns a new NetworkIO instrument.
func (NetworkIO) Add ¶
Add adds incr to the existing count.
All additional attrs passed are included in the recorded value.
func (NetworkIO) AttrNetworkIODirection ¶
func (NetworkIO) AttrNetworkIODirection(val NetworkIODirectionAttr) attribute.KeyValue
AttrNetworkIODirection returns an optional attribute for the "network.io.direction" semantic convention. It represents the network IO operation direction.
func (NetworkIO) Description ¶
Description returns the semantic convention description of the instrument
func (NetworkIO) Inst ¶
func (m NetworkIO) Inst() metric.Int64Counter
Inst returns the underlying metric instrument.
type NetworkIODirectionAttr ¶
type NetworkIODirectionAttr string
NetworkIODirectionAttr is an attribute conforming to the network.io.direction semantic conventions. It represents the network IO operation direction.
var ( // NetworkIODirectionTransmit is the none. NetworkIODirectionTransmit NetworkIODirectionAttr = "transmit" // NetworkIODirectionReceive is the none. NetworkIODirectionReceive NetworkIODirectionAttr = "receive" )
type OpenFileDescriptorCount ¶
type OpenFileDescriptorCount struct {
metric.Int64UpDownCounter
}
OpenFileDescriptorCount is an instrument used to record metric values conforming to the "process.open_file_descriptor.count" semantic conventions. It represents the number of file descriptors in use by the process.
func NewOpenFileDescriptorCount ¶
func NewOpenFileDescriptorCount( m metric.Meter, opt ...metric.Int64UpDownCounterOption, ) (OpenFileDescriptorCount, error)
NewOpenFileDescriptorCount returns a new OpenFileDescriptorCount instrument.
func (OpenFileDescriptorCount) Description ¶
func (OpenFileDescriptorCount) Description() string
Description returns the semantic convention description of the instrument
func (OpenFileDescriptorCount) Inst ¶
func (m OpenFileDescriptorCount) Inst() metric.Int64UpDownCounter
Inst returns the underlying metric instrument.
func (OpenFileDescriptorCount) Name ¶
func (OpenFileDescriptorCount) Name() string
Name returns the semantic convention name of the instrument.
func (OpenFileDescriptorCount) Unit ¶
func (OpenFileDescriptorCount) Unit() string
Unit returns the semantic convention unit of the instrument
type PagingFaultTypeAttr ¶
type PagingFaultTypeAttr string
PagingFaultTypeAttr is an attribute conforming to the process.paging.fault_type semantic conventions. It represents the type of page fault for this data point. Type `major` is for major/hard page faults, and `minor` is for minor/soft page faults.
var ( // PagingFaultTypeMajor is the none. PagingFaultTypeMajor PagingFaultTypeAttr = "major" // PagingFaultTypeMinor is the none. PagingFaultTypeMinor PagingFaultTypeAttr = "minor" )
type PagingFaults ¶
type PagingFaults struct {
metric.Int64Counter
}
PagingFaults is an instrument used to record metric values conforming to the "process.paging.faults" semantic conventions. It represents the number of page faults the process has made.
func NewPagingFaults ¶
func NewPagingFaults( m metric.Meter, opt ...metric.Int64CounterOption, ) (PagingFaults, error)
NewPagingFaults returns a new PagingFaults instrument.
func (PagingFaults) Add ¶
Add adds incr to the existing count.
All additional attrs passed are included in the recorded value.
func (PagingFaults) AttrPagingFaultType ¶
func (PagingFaults) AttrPagingFaultType(val PagingFaultTypeAttr) attribute.KeyValue
AttrPagingFaultType returns an optional attribute for the "process.paging.fault_type" semantic convention. It represents the type of page fault for this data point. Type `major` is for major/hard page faults, and `minor` is for minor/soft page faults.
func (PagingFaults) Description ¶
func (PagingFaults) Description() string
Description returns the semantic convention description of the instrument
func (PagingFaults) Inst ¶
func (m PagingFaults) Inst() metric.Int64Counter
Inst returns the underlying metric instrument.
func (PagingFaults) Name ¶
func (PagingFaults) Name() string
Name returns the semantic convention name of the instrument.
func (PagingFaults) Unit ¶
func (PagingFaults) Unit() string
Unit returns the semantic convention unit of the instrument
type ThreadCount ¶
type ThreadCount struct {
metric.Int64UpDownCounter
}
ThreadCount is an instrument used to record metric values conforming to the "process.thread.count" semantic conventions. It represents the process threads count.
func NewThreadCount ¶
func NewThreadCount( m metric.Meter, opt ...metric.Int64UpDownCounterOption, ) (ThreadCount, error)
NewThreadCount returns a new ThreadCount instrument.
func (ThreadCount) Description ¶
func (ThreadCount) Description() string
Description returns the semantic convention description of the instrument
func (ThreadCount) Inst ¶
func (m ThreadCount) Inst() metric.Int64UpDownCounter
Inst returns the underlying metric instrument.
func (ThreadCount) Name ¶
func (ThreadCount) Name() string
Name returns the semantic convention name of the instrument.
func (ThreadCount) Unit ¶
func (ThreadCount) Unit() string
Unit returns the semantic convention unit of the instrument
type Uptime ¶
type Uptime struct {
metric.Float64Gauge
}
Uptime is an instrument used to record metric values conforming to the "process.uptime" semantic conventions. It represents the time the process has been running.
func (Uptime) Description ¶
Description returns the semantic convention description of the instrument
func (Uptime) Inst ¶
func (m Uptime) Inst() metric.Float64Gauge
Inst returns the underlying metric instrument.