-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
Support for OpenMetrics standard #9547
Comments
next steps: look into creating a new parser using the existing Prometheus parser as a foundation to correctly parse the new features like info. |
Hello, |
We have also issues with consuming different OpenMetrics endpoints. Have trouble with timestamp format. OpenMetrics describes another timestamp format: Timestamps MUST be Unix Epoch in seconds. Maybe it's possible to add also this timestamp format to |
So we identified following main differences/evolution to prometheus format:
Short summary OpenMetrics vs. Prometheus format: https://www.robustperception.io/openmetrics-is-released/ |
While this is still in progress, is there any workaround that allows users to exclude or skip those OpenMetrics types like 'Info' and 'StateSet'? We are currently facing this issue in the usecase that opentelemetry java agent's prometheus exporter exports the metrics with 'Info' type but telegraf will just fail the whole parsing. |
@sirainen, @1tft and @yzhuang93 please test the binary in PR #15298, available as soon as CI finished the tests, and let me know if it works for you. Please be aware that by default |
Started some tests on base of script output ( |
@srebhan appreciate for the fix, i tried the build from your PR today as well, unfortunately, in my case when I specify the
If I change the |
Per the OpenMetrics spec, messages must end with
edit: opentelemetry -> openmetrics |
I see, then somehow the opentelemetry java agent is not exporting that to the output, let me double check the version I am using and retry with this build, thanks |
@yzhuang93 without the EOF, this is probably a prometheus message? |
@srebhan Yeah I think it is a Prometheus text format, it is exported by the https://github.com/open-telemetry/opentelemetry-java/blob/main/sdk-extensions/autoconfigure/README.md#prometheus-exporter, but what confuses me is that it does contain the
And if I use the Prometheus instead of telegraf to scrape the data, it does the parsing without issue. |
@yzhuang93 ok, so you should go with the prometheus spec then.... It also might be OpenMetrics 0.0.4 but this parser does not support that. It is however the same format as the Prometheus text format I believe with a few additional types... |
Got it, thanks for the info @srebhan |
@1tft just to be sure, are you fine with the PR or do you need more testing? |
@srebhan Yes. But had no chance to test with an endpoint of a standard software product. |
I'll mark the PR as ready then. Please report any issues once you extend your use-case! |
Feature Request
Telegraf supports Prometheus format, which was used as the basis for the OpenMetrics standard. However, there are some differences. Most importantly from my point of view, Dovecot v2.3.14+ uses the "info" type, which Telegraf treats as invalid. It would be nice if Telegraf would add support for this to make it more OpenMetrics standard compliant. (This can't be fixed on Dovecot side without making it violate the OpenMetrics standard, or adding a new configuration option to choose the behavior.)
See https://github.com/OpenObservability/OpenMetrics/blob/main/specification/OpenMetrics.md
The text was updated successfully, but these errors were encountered: