Fix hyper-v collector memory metric descriptions

Signed-off-by: Andrew Banman <abanman@pnri.org>
This commit is contained in:
Andrew Banman
2022-05-12 09:48:51 -07:00
parent a01f72a8b0
commit 68c338b479

View File

@@ -610,61 +610,61 @@ func NewHyperVCollector() (Collector, error) {
VMMemoryAddedMemory: prometheus.NewDesc( VMMemoryAddedMemory: prometheus.NewDesc(
prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "added"), prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "added"),
"", "This counter represents memory in MB added to the VM",
[]string{"vm"}, []string{"vm"},
nil, nil,
), ),
VMMemoryAveragePressure: prometheus.NewDesc( VMMemoryAveragePressure: prometheus.NewDesc(
prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "pressure_average"), prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "pressure_average"),
"This counter represents the average pressure in the VM.", "This gauge represents the average pressure in the VM.",
[]string{"vm"}, []string{"vm"},
nil, nil,
), ),
VMMemoryCurrentPressure: prometheus.NewDesc( VMMemoryCurrentPressure: prometheus.NewDesc(
prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "pressure_current"), prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "pressure_current"),
"This counter represents the current pressure in the VM.", "This gauge represents the current pressure in the VM.",
[]string{"vm"}, []string{"vm"},
nil, nil,
), ),
VMMemoryGuestVisiblePhysicalMemory: prometheus.NewDesc( VMMemoryGuestVisiblePhysicalMemory: prometheus.NewDesc(
prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "physical_guest_visible"), prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "physical_guest_visible"),
"'This counter represents the amount of memory visible in the VM.'", "'This gauge represents the amount of memory in MB visible to the VM guest.'",
[]string{"vm"}, []string{"vm"},
nil, nil,
), ),
VMMemoryMaximumPressure: prometheus.NewDesc( VMMemoryMaximumPressure: prometheus.NewDesc(
prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "pressure_maximum"), prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "pressure_maximum"),
"This counter represents the maximum pressure band in the VM.", "This gauge represents the maximum pressure band in the VM.",
[]string{"vm"}, []string{"vm"},
nil, nil,
), ),
VMMemoryMemoryAddOperations: prometheus.NewDesc( VMMemoryMemoryAddOperations: prometheus.NewDesc(
prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "add_operations"), prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "add_operations"),
"", "This counter represents the number of operations adding memory to the VM.",
[]string{"vm"}, []string{"vm"},
nil, nil,
), ),
VMMemoryMemoryRemoveOperations: prometheus.NewDesc( VMMemoryMemoryRemoveOperations: prometheus.NewDesc(
prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "remove_operations"), prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "remove_operations"),
"", "This counter represents the number of operations removing memory from the VM.",
[]string{"vm"}, []string{"vm"},
nil, nil,
), ),
VMMemoryMinimumPressure: prometheus.NewDesc( VMMemoryMinimumPressure: prometheus.NewDesc(
prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "pressure_minimum"), prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "pressure_minimum"),
"This counter represents the minmum pressure band in the VM.", "This gauge represents the minmum pressure band in the VM.",
[]string{"vm"}, []string{"vm"},
nil, nil,
), ),
VMMemoryPhysicalMemory: prometheus.NewDesc( VMMemoryPhysicalMemory: prometheus.NewDesc(
prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "physical_memory"), prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "physical_memory"),
"This counter represents the current amount of memory in the VM.", "This gauge represents the current amount of memory in MB assigned to the VM.",
[]string{"vm"}, []string{"vm"},
nil, nil,
), ),
VMMemoryRemovedMemory: prometheus.NewDesc( VMMemoryRemovedMemory: prometheus.NewDesc(
prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "removed"), prometheus.BuildFQName(Namespace, buildSubsystemName("vm_memory"), "removed"),
"", "This counter represents memory in MB removed from the VM",
[]string{"vm"}, []string{"vm"},
nil, nil,
), ),