-
Notifications
You must be signed in to change notification settings - Fork 36
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
Prometheus endpoint does not provide metric name #11
Comments
@kenfinnigan can you look into this or assign appropriate person, please ? |
@rsvoboda It will be looked at when we've scheduled the work |
@jmesnil I think I like the idea, can you please open an issue in @eclipse/microprofile-metrics ? We could just append the original name in parens at the end of the description, but it would not exactly follow the spec ("luckily" there are no tests for the A patch should be relatively straight-forward as https://github.com/smallrye/smallrye-metrics/blob/master/implementation/src/main/java/io/smallrye/metrics/exporters/PrometheusExporter.java#L295 is creating the |
While playing with the
jvm.uptime
metric, I noticed that the Prometheus endpoint does not contain the actual name of the metric.When I tried to get the metric only for `jvm.uptime, I tried the name from the previous result:
It turns ou that I need to use the original metric name
jvm.uptime
(which is obvious in retrospect):However there is no way to know the actual metric name from the Prometheus output itself as the
metrics/base
endpoint only mentionsjvm_uptime_seconds
and neverjvm.uptime
.Could we improve somehow the Prometheus export format so that it is possible to drill down the metric from their scope without having to mentally convert the metric name from MicroProfile to the Prometheus one according to the spec (section 3.2.1. Translation rules for metric names)?
The text was updated successfully, but these errors were encountered: