Skip to content

Commit

Permalink
Fix for amazon prom vs prom
Browse files Browse the repository at this point in the history
  • Loading branch information
ian-bartholomew committed Sep 29, 2022
1 parent e689760 commit d0bc127
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion internal/pkg/convert/convert.go
Original file line number Diff line number Diff line change
Expand Up @@ -355,13 +355,20 @@ func getN9MetricSource(m v1.MetricSource) (nobl9v1alpha.MetricSpec, error) {
Query: &query,
},
}
case supportedMetricSources["Prometheus"], supportedMetricSources["AmazonPrometheus"]:
case supportedMetricSources["Prometheus"]:
query := m.MetricSourceSpec["promql"]
ms = nobl9v1alpha.MetricSpec{
Prometheus: &nobl9v1alpha.PrometheusMetric{
PromQL: &query,
},
}
case supportedMetricSources["AmazonPrometheus"]:
query := m.MetricSourceSpec["promql"]
ms = nobl9v1alpha.MetricSpec{
AmazonPrometheus: &nobl9v1alpha.AmazonPrometheusMetric{
PromQL: &query,
},
}
case supportedMetricSources["NewRelic"]:
query := m.MetricSourceSpec["nrql"]
ms = nobl9v1alpha.MetricSpec{
Expand Down

0 comments on commit d0bc127

Please sign in to comment.