Open
Conversation
|
Bugbot Autofix prepared fixes for 1 of the 1 bugs found in the latest run.
Or push these changes by commenting: Preview (10e282d7fe)diff --git a/integration/asserts.go b/integration/asserts.go
--- a/integration/asserts.go
+++ b/integration/asserts.go
@@ -35,7 +35,7 @@
serviceMetricsPrefixes = map[ServiceType][]string{
Distributor: {},
Ingester: {"!cortex_ingester_client", "cortex_ingester"}, // The metrics prefix cortex_ingester_client may be used by other components so we ignore it.
- Querier: {"!cortex_querier_storegateway", "!cortex_querier_blocks", "!cortex_querier_queries", "!cortex_querier_query", "cortex_querier", "!cortex_querier_series_labels_total", "!cortex_querier_series_labels_deduplicated_total"}, // The metrics prefix cortex_querier_storegateway, cortex_querier_blocks, cortex_querier_queries, cortex_querier_query, cortex_querier_series_labels_total, and cortex_querier_series_labels_deduplicated_total may be used by other components so we ignore it.
+ Querier: {"!cortex_querier_storegateway", "!cortex_querier_blocks", "!cortex_querier_queries", "!cortex_querier_query", "!cortex_querier_series_labels_total", "!cortex_querier_series_labels_deduplicated_total", "cortex_querier"}, // The metrics prefix cortex_querier_storegateway, cortex_querier_blocks, cortex_querier_queries, cortex_querier_query, cortex_querier_series_labels_total, and cortex_querier_series_labels_deduplicated_total may be used by other components so we ignore it.
QueryFrontend: {"cortex_frontend", "cortex_query_frontend"},
QueryScheduler: {"cortex_query_scheduler"},
AlertManager: {"cortex_alertmanager"}, |
charleskorn
reviewed
Feb 17, 2026
integration/asserts.go
Outdated
| Ingester: {"!cortex_ingester_client", "cortex_ingester"}, // The metrics prefix cortex_ingester_client may be used by other components so we ignore it. | ||
| Querier: {"!cortex_querier_storegateway", "!cortex_querier_blocks", "!cortex_querier_queries", "!cortex_querier_query", "cortex_querier"}, // The metrics prefix cortex_querier_storegateway, cortex_querier_blocks, cortex_querier_queries, and cortex_querier_query may be used by other components so we ignore it. | ||
| Ingester: {"!cortex_ingester_client", "cortex_ingester"}, // The metrics prefix cortex_ingester_client may be used by other components so we ignore it. | ||
| Querier: {"!cortex_querier_storegateway", "!cortex_querier_blocks", "!cortex_querier_queries", "!cortex_querier_query", "!cortex_querier_series_labels_total", "!cortex_querier_series_labels_deduplicated_total", "cortex_querier"}, // The metrics prefix cortex_querier_storegateway, cortex_querier_blocks, cortex_querier_queries, cortex_querier_query, cortex_querier_series_labels_total, and cortex_querier_series_labels_deduplicated_total may be used by other components so we ignore it. |
Contributor
There was a problem hiding this comment.
What other component would see the new metrics? The ruler?
Contributor
Author
There was a problem hiding this comment.
Yes we added !cortex_querier_series_labels_total", "!cortex_querier_series_labels_deduplicated_total" on that line 38 because Ruler component also can use it when using embedded mode querier.
Contributor
There was a problem hiding this comment.
Could you please add a comment here explaining that?
Contributor
Author
There was a problem hiding this comment.
Updated in the last two commits
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
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.

Follow up #14148. Add metrics on SeriesLabelsDeduplicator so that we can measure the impact better.
More context in MQE sync 17 Feb 2026 note.
What this PR does
Which issue(s) this PR fixes or relates to
Fixes #
Checklist
CHANGELOG.mdupdated - the order of entries should be[CHANGE],[FEATURE],[ENHANCEMENT],[BUGFIX]. If changelog entry is not needed, please add thechangelog-not-neededlabel to the PR.about-versioning.mdupdated with experimental features.Note
Low Risk
Instrumentation-only change that adds counters and updates call sites to pass a registerer; main risk is minor metric/registry wiring issues in tests or embedded-querier deployments.
Overview
Adds Prometheus counters to
SeriesLabelsDeduplicatorto track how many series labels are processed vs deduplicated (cortex_querier_labels_deduplicator_processed_total,..._deduplicated_total).Threads a shared metrics instance through
ContextWithNewSeriesLabelsDeduplicatorandNewMemoryTrackingQueryable, updates affected tests/benchmarks to provide a registry, and adjusts integration metric-prefix assertions to ignore these newcortex_querier_*metrics when also exposed by embedded-querier Ruler.Written by Cursor Bugbot for commit ebb0b80. This will update automatically on new commits. Configure here.