-
Notifications
You must be signed in to change notification settings - Fork 789
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
OpenMetrics support for textfile collector #957
Comments
Hello, I am not opposed to adding a function to |
Thank you for the interest :) Honestly, can't give too many specifics right now, as I'm waiting for approval from the company I work for to actually Open Source the tool I'm building. What I can say right now is that it's a console app and Python API for converting reports outputted by "a tool" into the OpenMetrics text format. Such metrics are then meant to be pushed into Grafana (data source), via VictoriaMetrics API. |
Once it's Open Sourced I'll be sure to provide a link here, so you can see the use-case more clearly - there are a few reasons I've opted in for OpenMetrics in lieu of Prometheus text format... |
As promised, https://pypi.org/project/locust_csv2openmetrics/ has (finally) hit 1.0.0 today. We use this tool to convert locust’s load test CSV formatted reports into the OpenMetrics text format, pushing the obtained metrics into Grafana (data source), via VictoriaMetrics API. |
Because these load tests are run non-continuously and at irregular time intervals we need to push their metrics into Grafana (data source), as opposed to the much more common way of Prometheus pulling data from a load-tests-like service to collect the metrics. I hope this clarifies our use case. |
That use case makes sense to me, it is also the format you need to backfill data into Prometheus using promtool. That said, it looks like what you did is the correct thing to do, call generate_latest and save to a file. The reason |
Currently
prometheus_client.exposition.write_to_textfile
doesn't support the OpenMetrics text format, which I'm addressing with this (private) hack:Would your project be interested in a non-hacky (as is the case above) OpenMetrics support for textfile collector?
The text was updated successfully, but these errors were encountered: