types

package
v0.1.0-alpha Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2024 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Labels

type Labels map[string]string

type Metric

type Metric struct {
	Type        MetricType `json:"type"`
	ValueType   ValueType  `json:"value_type"`
	StringValue *string    `json:"string_value"`
	FloatValue  *float64   `json:"float_value"`
	IntValue    *int       `json:"int_value"`
	BoolValue   *bool      `json:"bool_value"`
	Unit        string     `json:"unit,omitempty"`
	Timestamp   int64      `json:"timestamp"`
	Labels      Labels     `json:"labels,omitempty"`
}

type MetricType

type MetricType string
const (
	MetricCPUModel         MetricType = "cpu.model"
	MetricCPUUsage         MetricType = "cpu.usage"
	MetricCPUCountPhysical MetricType = "cpu.count_physical"
	MetricCPUCountLogical  MetricType = "cpu.count_logical"

	MetricMemoryUsage MetricType = "memory.usage"
	MetricMemoryTotal MetricType = "memory.total"
	MetricMemoryFree  MetricType = "memory.free"

	MetricDiskUsage MetricType = "disk.usage"
	MetricDiskUsed  MetricType = "disk.used"
	MetricDiskFree  MetricType = "disk.free"
	MetricDiskTotal MetricType = "disk.total"
)

type ValueType

type ValueType string
const (
	ValueTypeString ValueType = "string"
	ValueTypeFloat  ValueType = "float"
	ValueTypeBool   ValueType = "bool"
	ValueTypeInt    ValueType = "int"
)

Jump to

Keyboard shortcuts

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