Skip to content

fix query frontend per tenant metrics leak when cleaning up user labels #6698

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
merged 2 commits into from
Apr 15, 2025

Conversation

yeya24
Copy link
Contributor

@yeya24 yeya24 commented Apr 15, 2025

What this PR does:

After #6470, we added another label to QFE per user metrics. This requires us to change how we clean up those metrics. Instead of DeleteLabelValues, we need to change to use util.DeleteMatchingLabels instead.

Also created a unit test to capture this regression

Which issue(s) this PR fixes:
Fixes #

Checklist

  • Tests updated
  • Documentation added
  • CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX]

Signed-off-by: Ben Ye <benye@amazon.com>
@SungJin1212
Copy link
Member

Thanks!

Copy link
Contributor

@justinjung04 justinjung04 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch, thank you!

@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Apr 15, 2025
@yeya24 yeya24 merged commit 15a9eae into cortexproject:master Apr 15, 2025
17 checks passed
@yeya24 yeya24 deleted the fix-qfe-metrics-leak branch April 15, 2025 18:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/query-frontend lgtm This PR has been approved by a maintainer size/L
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants