# Functions
AddGlobalLabel adds a global label to all metrics.
DiskFree returns the available disk space (from the program's data root).
DiskTotal returns the total disk space (from the program's data root).
DiskUsed returns the used disk space (from the program's data root).
DiskUsedPercent returns the percent of used disk space (from the program's data root).
EnableMetricPersistence enables metric persistence for metrics that opted for it.
ExportMetrics exports all registered metrics.
ExportValues exports the values of all supported metrics.
LoadAvg1 returns the 1-minute average system load.
LoadAvg15 returns the 15-minute average system load.
LoadAvg5 returns the 5-minute average system load.
MemAvailable returns the available system memory.
MemTotal returns the total system memory.
MemUsed returns the used system memory.
MemUsedPercent returns the percent of used system memory.
NewCounter registers a new counter metric.
NewFetchingCounter registers a new fetching counter metric.
NewGauge registers a new gauge metric.
NewHistogram registers a new histogram metric.
SetNamespace sets the namespace for all metrics.
WriteMetrics writes all metrics that match the given permission and expertiseLevel to the given writer.
# Constants
PrometheusFormatRequirement is required format defined by prometheus for metric and label names.
# Variables
Configuration Keys.
Configuration Keys.
Configuration Keys.
ErrAlreadyInitialized is returned when trying to initialize an option more than once or if the time window for initializing is over.
ErrAlreadyRegistered is returned when a metric with the same ID is registered again.
ErrAlreadySet is returned when a value is already set and cannot be changed.
ErrAlreadyStarted is returned when an operation is only valid before the first metric is registered, and is called after.
ErrInvalidOptions is returned when invalid options where provided.
# Structs
Counter is a counter metric.
FetchingCounter is a counter metric that fetches the values via a function call.
Gauge is a gauge metric.
Histogram is a histogram metric.
MetricExport is used to export a metric and its current value.
Options can be used to set advanced metric settings.
# Interfaces
FloatMetric is an interface for special functions of float metrics.
Metric represents one or more metrics.
UIntMetric is an interface for special functions of uint metrics.