Skip to content

Commit

Permalink
Updating hyper_pod_* metric names to hyperpod_* (#228)
Browse files Browse the repository at this point in the history
  • Loading branch information
spanaik authored Aug 23, 2024
1 parent d503b27 commit bfabe7d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion internal/aws/containerinsight/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ func getPrefixByMetricType(mType string) string {
instanceNetPrefix := "instance_interface_"
nodeNetPrefix := "node_interface_"
nodeEfaPrefix := "node_efa_"
hyperPodNodeHealthStatus := "hyper_pod_node_health_status_"
hyperPodNodeHealthStatus := "hyperpod_node_health_status_"
podPrefix := "pod_"
podNetPrefix := "pod_interface_"
podEfaPrefix := "pod_efa_"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -441,10 +441,10 @@ func TestK8sAPIServer_GetMetrics(t *testing.T) {
assert.Equal(t, "HyperPodNode", getStringAttrVal(metric, ci.MetricType))
assert.Equal(t, "ip-192-168-57-23.us-west-2.compute.internal", getStringAttrVal(metric, ci.NodeNameKey))
assert.Equal(t, "ip-192-168-57-23.us-west-2.compute.internal", getStringAttrVal(metric, ci.InstanceID))
assertMetricValueEqual(t, metric, "hyper_pod_node_health_status_unschedulable_pending_reboot", int64(0))
assertMetricValueEqual(t, metric, "hyper_pod_node_health_status_schedulable", int64(1))
assertMetricValueEqual(t, metric, "hyper_pod_node_health_status_unschedulable", int64(0))
assertMetricValueEqual(t, metric, "hyper_pod_node_health_status_unschedulable_pending_replacement", int64(0))
assertMetricValueEqual(t, metric, "hyperpod_node_health_status_unschedulable_pending_reboot", int64(0))
assertMetricValueEqual(t, metric, "hyperpod_node_health_status_schedulable", int64(1))
assertMetricValueEqual(t, metric, "hyperpod_node_health_status_unschedulable", int64(0))
assertMetricValueEqual(t, metric, "hyperpod_node_health_status_unschedulable_pending_replacement", int64(0))
default:
assert.Fail(t, "Unexpected metric type: "+metricType)
}
Expand Down

0 comments on commit bfabe7d

Please sign in to comment.