-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
fix(prometheus): improve logging when having the inconsistent labels count #13020
fix(prometheus): improve logging when having the inconsistent labels count #13020
Conversation
…s count Currently, the prometheus plugin will log the following error if we have encountered the inconsisent label count while debugging: ``` [error]... inconsistent labels count, expected 6, got 5 ``` It's hard to identify which metric is going wrong, and it will be helpful if we can bring the metric name as well: ``` [error]... metric 'bandwidth_bytes' has the inconsistent labels count, expected 6, got 5 ```
@oowl Would you mind taking a look at this PR? |
https://github.com/Kong/kong/actions/runs/9072858739/job/24943120249?pr=13020#step:20:2126 The CI failure is not related to this PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, Thx
@chronolaw @StarlightIbuki could you help to take a look at this PR? |
@chronolaw @oowl @StarlightIbuki, is this PR good to merge? |
@ADD-SP Would you mind having a look at this PR? |
Co-authored-by: Qi <call_far@outlook.com>
@git-hulk Thanks for your contribution! |
Successfully created cherry-pick PR for |
@ADD-SP Thank you! |
Summary
Currently, the Prometheus plugin will log the following error if we have encountered an inconsistent label count while debugging:
It's hard to identify which metric is going wrong, and it will be helpful if we can bring the metric name as well:
Checklist
changelog/unreleased/kong
orskip-changelog
label added on PR if changelog is unnecessary. README.md