make cpu metrics consistent with v2 docs
Signed-off-by: Boris Popovschi <zyqsempai@mail.ru>
This commit is contained in:
@@ -26,7 +26,7 @@ import (
|
|||||||
|
|
||||||
var cpuMetrics = []*metric{
|
var cpuMetrics = []*metric{
|
||||||
{
|
{
|
||||||
name: "cpu_usage",
|
name: "cpu_usage_usec",
|
||||||
help: "Total cpu usage (cgroup v2)",
|
help: "Total cpu usage (cgroup v2)",
|
||||||
unit: metrics.Unit("microseconds"),
|
unit: metrics.Unit("microseconds"),
|
||||||
vt: prometheus.GaugeValue,
|
vt: prometheus.GaugeValue,
|
||||||
@@ -42,7 +42,7 @@ var cpuMetrics = []*metric{
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "cpu_user_usage",
|
name: "cpu_user_usec",
|
||||||
help: "Current cpu usage in user space (cgroup v2)",
|
help: "Current cpu usage in user space (cgroup v2)",
|
||||||
unit: metrics.Unit("microseconds"),
|
unit: metrics.Unit("microseconds"),
|
||||||
vt: prometheus.GaugeValue,
|
vt: prometheus.GaugeValue,
|
||||||
@@ -58,7 +58,7 @@ var cpuMetrics = []*metric{
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "cpu_system_usage",
|
name: "cpu_system_usec",
|
||||||
help: "Current cpu usage in kernel space (cgroup v2)",
|
help: "Current cpu usage in kernel space (cgroup v2)",
|
||||||
unit: metrics.Unit("microseconds"),
|
unit: metrics.Unit("microseconds"),
|
||||||
vt: prometheus.GaugeValue,
|
vt: prometheus.GaugeValue,
|
||||||
|
@@ -74,7 +74,7 @@ var memoryMetrics = []*metric{
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "memory_swap_Limit",
|
name: "memory_swap_limit",
|
||||||
help: "Current swap usage limit (cgroup v2)",
|
help: "Current swap usage limit (cgroup v2)",
|
||||||
unit: metrics.Bytes,
|
unit: metrics.Bytes,
|
||||||
vt: prometheus.GaugeValue,
|
vt: prometheus.GaugeValue,
|
||||||
|
Reference in New Issue
Block a user