Преглед изворни кода

Merge pull request #992 from kubecost/mmd/emit-gpu-cost

Emit the node_gpu_hourly_cost metric
Michael Dresser пре 4 година
родитељ
комит
47723ce94e
1 измењених фајлова са 1 додато и 0 уклоњено
  1. 1 0
      pkg/costmodel/metrics.go

+ 1 - 0
pkg/costmodel/metrics.go

@@ -472,6 +472,7 @@ func (cmme *CostModelMetricsEmitter) Start() bool {
 				}
 				}
 
 
 				cmme.GPUCountRecorder.WithLabelValues(nodeName, nodeName, nodeType, nodeRegion, node.ProviderID).Set(gpu)
 				cmme.GPUCountRecorder.WithLabelValues(nodeName, nodeName, nodeType, nodeRegion, node.ProviderID).Set(gpu)
+				cmme.GPUPriceRecorder.WithLabelValues(nodeName, nodeName, nodeType, nodeRegion, node.ProviderID).Set(gpuCost)
 
 
 				const outlierFactor float64 = 30
 				const outlierFactor float64 = 30
 				// don't record cpuCost, ramCost, or gpuCost in the case of wild outliers
 				// don't record cpuCost, ramCost, or gpuCost in the case of wild outliers