Skip to content
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

add Kafka metric support for 3 labels #45

Merged
merged 2 commits into from
Mar 17, 2022

Conversation

ctrlaltluc
Copy link

Q A
Bug fix? yes
New feature? no
API breaks? no
Deprecations? no
Related tickets n/a
License Apache 2.0

What's in this PR?

PR enables Kafka JMX metrics with 3 labels, for both counters and gauges.

Why?

The current JMX Prometheus agent configuration does not support more than 2 JMX metric labels.
This results in some labels being erroneously parsed e.g.

kafka_network_requestmetrics_fifteenminuterate{name_ErrorsPerSec_request="ApiVersions",error="NONE",} 0.7567675751254123

instead of:

kafka_network_requestmetrics_fifteenminuterate{name="ErrorsPerSec",request="ApiVersions",error="NONE",} 0.786777163057294

Checklist

  • Implementation tested
  • Error handling code meets the guideline
  • Logging code meets the guideline
  • User guide and development docs updated (if needed)

@ctrlaltluc ctrlaltluc self-assigned this Mar 17, 2022
@ctrlaltluc ctrlaltluc requested a review from amuraru March 17, 2022 08:25
@amuraru
Copy link

amuraru commented Mar 17, 2022

thanks for this PR @ctrlaltluc - please also file this PR against banzaicloud/koperator

Co-authored-by: Adrian Muraru <[email protected]>
@ctrlaltluc
Copy link
Author

thanks for this PR @ctrlaltluc - please also file this PR against banzaicloud/koperator

thanks for reviewing @amuraru - see banzaicloud#778

@ctrlaltluc ctrlaltluc merged commit 85b03c6 into adobe:master Mar 17, 2022
@ctrlaltluc ctrlaltluc deleted the kafka-metric-labels-jmx branch March 17, 2022 09:00
amuraru added a commit that referenced this pull request Mar 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants