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

Prometheus exporter: Unit in metric names #927

Closed
dashpole opened this issue Dec 6, 2022 · 0 comments · Fixed by #1157
Closed

Prometheus exporter: Unit in metric names #927

dashpole opened this issue Dec 6, 2022 · 0 comments · Fixed by #1157
Labels
A-metrics Area: issues related to metrics

Comments

@dashpole
Copy link

dashpole commented Dec 6, 2022

From the OTel prometheus spec:

The unit MUST be added as a suffix to the metric name, and SHOULD be converted to base units recommended by OpenMetrics when possible. The unit suffix comes before any type-specific suffixes.

I would recommend against converting to base units (e.g. converting milliseconds to seconds), but would recommend converting abbreviations to full words for commonly-used units (e.g. ms to milliseconds).

As an example of what metrics should look like when this is complete, a metric with name foo, and unit ms should have the resulting name: foo_milliseconds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-metrics Area: issues related to metrics
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants