From a4a94300e84067e546888b6409fa48eeadacd2ce Mon Sep 17 00:00:00 2001 From: Takuya Iwatsuka Date: Tue, 22 Aug 2023 20:46:21 +0900 Subject: [PATCH] fix type of platform energy obtained from system (#874) Signed-off-by: Takuya Iwatsuka --- pkg/collector/node_energy_collector.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/collector/node_energy_collector.go b/pkg/collector/node_energy_collector.go index 79fef2fe6f..d7de06769c 100644 --- a/pkg/collector/node_energy_collector.go +++ b/pkg/collector/node_energy_collector.go @@ -47,7 +47,7 @@ func (c *Collector) updateNodeResourceUsage() { func (c *Collector) updatePlatformEnergy() { if platform.IsSystemCollectionSupported() { nodePlatformEnergy, _ := platform.GetAbsEnergyFromPlatform() - c.NodeMetrics.SetNodePlatformEnergy(nodePlatformEnergy, counter, absPower) + c.NodeMetrics.SetNodePlatformEnergy(nodePlatformEnergy, gauge, absPower) } else if model.IsNodePlatformPowerModelEnabled() { model.UpdateNodePlatformEnergy(&c.NodeMetrics) }