Skip to content

Commit

Permalink
Add AWS Neuron metric origin (#28088)
Browse files Browse the repository at this point in the history
  • Loading branch information
dkirov-dd authored Aug 5, 2024
1 parent 51213dc commit 1302b88
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 1 deletion.
5 changes: 5 additions & 0 deletions pkg/metrics/metricsource.go
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,7 @@ const (
MetricSourceWmiCheck
MetricSourceYarn
MetricSourceZk
MetricSourceAwsNeuron
)

// String returns a string representation of MetricSource
Expand Down Expand Up @@ -841,6 +842,8 @@ func (ms MetricSource) String() string {
return "zabbix"
case MetricSourceZenohRouter:
return "zenoh_router"
case MetricSourceAwsNeuron:
return "aws_neuron"
default:
return "<unknown>"
}
Expand Down Expand Up @@ -1361,6 +1364,8 @@ func CheckNameToMetricSource(name string) MetricSource {
return MetricSourceZabbix
case "zenoh_router":
return MetricSourceZenohRouter
case "aws_neuron":
return MetricSourceAwsNeuron
default:
return MetricSourceUnknown
}
Expand Down
5 changes: 4 additions & 1 deletion pkg/serializer/internal/metrics/origin_mapping.go
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,8 @@ func metricSourceToOriginCategory(ms metrics.MetricSource) int32 {
metrics.MetricSourceWindowsService,
metrics.MetricSourceWmiCheck,
metrics.MetricSourceYarn,
metrics.MetricSourceZk:
metrics.MetricSourceZk,
metrics.MetricSourceAwsNeuron:
return 11 // integrationMetrics
default:
return 0
Expand Down Expand Up @@ -847,6 +848,8 @@ func metricSourceToOriginService(ms metrics.MetricSource) int32 {
return 399
case metrics.MetricSourceVllm:
return 412
case metrics.MetricSourceAwsNeuron:
return 413
default:
return 0
}
Expand Down
11 changes: 11 additions & 0 deletions releasenotes/notes/aws_neuron_origin-98d361379b1c1a7b.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Each section from every release note are combined when the
# CHANGELOG.rst is rendered. So the text needs to be worded so that
# it does not depend on any information only available in another
# section. This may mean repeating some details, but each section
# must be readable independently of the other.
#
# Each section note must be formatted as reStructuredText.
---
other:
- |
Add metric origin for the AWS Neuron integration

0 comments on commit 1302b88

Please sign in to comment.