From 76081d92f2c0e5fa3b74ad4f9b66cf67994b8a27 Mon Sep 17 00:00:00 2001 From: Antoine Toulme Date: Fri, 27 Sep 2024 14:35:38 -0700 Subject: [PATCH] [exporter/signalfx] do not exclude the metric container.memory.working_set --- .chloggen/remove_exclusion_rule.yaml | 27 +++++++++++++++++++ exporter/signalfxexporter/factory_test.go | 2 +- .../internal/translation/default_metrics.go | 2 +- .../non_default_metrics_otel_convention.json | 3 --- 4 files changed, 29 insertions(+), 5 deletions(-) create mode 100644 .chloggen/remove_exclusion_rule.yaml diff --git a/.chloggen/remove_exclusion_rule.yaml b/.chloggen/remove_exclusion_rule.yaml new file mode 100644 index 000000000000..e571a15daafd --- /dev/null +++ b/.chloggen/remove_exclusion_rule.yaml @@ -0,0 +1,27 @@ +# Use this changelog template to create an entry for release notes. + +# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix' +change_type: breaking + +# The name of the component, or a single word describing the area of concern, (e.g. filelogreceiver) +component: signalfxexporter + +# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`). +note: Do not exclude the metric `container.memory.working_set` + +# Mandatory: One or more tracking issues related to the change. You can use the PR number here if no issue exists. +issues: [] + +# (Optional) One or more lines of additional information to render under the primary note. +# These lines will be padded with 2 spaces and then inserted directly into the document. +# Use pipe (|) for multiline entries. +subtext: + +# If your change doesn't affect end users or the exported elements of any package, +# you should instead start your pull request title with [chore] or use the "Skip Changelog" label. +# Optional: The change log or logs in which this entry should be included. +# e.g. '[user]' or '[user, api]' +# Include 'user' if the change is relevant to end users. +# Include 'api' if there is a change to a library API. +# Default: '[user]' +change_logs: [] diff --git a/exporter/signalfxexporter/factory_test.go b/exporter/signalfxexporter/factory_test.go index e762f179ee4f..eac89f009426 100644 --- a/exporter/signalfxexporter/factory_test.go +++ b/exporter/signalfxexporter/factory_test.go @@ -600,7 +600,7 @@ func TestDefaultExcludes_not_translated(t *testing.T) { require.NoError(t, err) md := getMetrics(metrics) - require.Equal(t, 69, md.ResourceMetrics().At(0).ScopeMetrics().At(0).Metrics().Len()) + require.Equal(t, 68, md.ResourceMetrics().At(0).ScopeMetrics().At(0).Metrics().Len()) dps := converter.MetricsToSignalFxV2(md) require.Empty(t, dps) } diff --git a/exporter/signalfxexporter/internal/translation/default_metrics.go b/exporter/signalfxexporter/internal/translation/default_metrics.go index d0d5fc71156b..14e94d853108 100644 --- a/exporter/signalfxexporter/internal/translation/default_metrics.go +++ b/exporter/signalfxexporter/internal/translation/default_metrics.go @@ -121,7 +121,7 @@ exclude_metrics: - /^(?i:(container)|(k8s\.node)|(k8s\.pod))\.memory\.page_faults$/ - /^(?i:(container)|(k8s\.node)|(k8s\.pod))\.memory\.rss$/ - /^(?i:(k8s\.node)|(k8s\.pod))\.memory\.usage$/ - - /^(?i:(container)|(k8s\.node)|(k8s\.pod))\.memory\.working_set$/ + - /^(?i:(k8s\.node)|(k8s\.pod))\.memory\.working_set$/ # matches (k8s.node|k8s.pod).filesystem... - /^k8s\.(?i:(node)|(pod))\.filesystem\.available$/ diff --git a/exporter/signalfxexporter/testdata/json/non_default_metrics_otel_convention.json b/exporter/signalfxexporter/testdata/json/non_default_metrics_otel_convention.json index e9ea9839db75..fc996acca3df 100644 --- a/exporter/signalfxexporter/testdata/json/non_default_metrics_otel_convention.json +++ b/exporter/signalfxexporter/testdata/json/non_default_metrics_otel_convention.json @@ -131,9 +131,6 @@ { "container.memory.rss": null }, - { - "container.memory.working_set": null - }, { "k8s.pod.memory.available": null },