-
Notifications
You must be signed in to change notification settings - Fork 229
[nr-k8s-otel-collector] Adding ksmSelector for prometheus receiver #1966
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
dbudziwojskiNR
merged 23 commits into
newrelic:master
from
tviaud:otel-collector-ksm-label-selector
Nov 5, 2025
Merged
[nr-k8s-otel-collector] Adding ksmSelector for prometheus receiver #1966
dbudziwojskiNR
merged 23 commits into
newrelic:master
from
tviaud:otel-collector-ksm-label-selector
Nov 5, 2025
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Contributor
|
@tviaud, thanks for the PR! This looks great. Just left a few comments and we can work to get this merged. Thank you! |
Co-authored-by: Daniel Budziwojski <[email protected]>
Co-authored-by: Daniel Budziwojski <[email protected]>
dbudziwojskiNR
requested changes
Oct 27, 2025
…ector-ksm-label-selector
…/helm-charts into otel-collector-ksm-label-selector
dbudziwojskiNR
previously approved these changes
Nov 3, 2025
…/helm-charts into otel-collector-ksm-label-selector
dbudziwojskiNR
approved these changes
Nov 5, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Is this a new chart
No
What this PR does / why we need it:
This pull request adds support for customising which
kube-state-metricsinstance is targeted by the Prometheus receiver in the otel deployment. This is useful for clusters running multiple kube-state-metrics instances, allowing users to specify a label selector to avoid scraping duplicate metrics.This is mostly mirroring what's done for the
ksmcomponent in thenewrelic-infrastructurechart: https://github.com/newrelic/nri-kubernetes/blob/main/charts/newrelic-infrastructure/values.yaml#L255.This would be useful in migration cases to keep
nri-bundleandnr-k8s-otel-collectorup at the same time for example.Which issue this PR fixes
(optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)format, will close that issue when PR gets merged)Special notes for your reviewer:
Checklist
[Place an '[x]' (no spaces) in all applicable fields. Please remove unrelated fields.]
[mychartname])Release Notes to Publish (nr-k8s-otel-collector)
If this PR contains changes in
nr-k8s-otel-collector, please complete the following section. All other charts should ignore this section.🚀 What's Changed
receivers.prometheus.ksmSelectorto prevent duplicate metric scraping when running multiple kube-state-metrics instances in the same cluster (e.g., during migration from nri-bundle to nr-k8s-otel-collector).