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 openmetrics format parser #311

Closed
wants to merge 3 commits into from

Conversation

ide-rea
Copy link

@ide-rea ide-rea commented Jun 18, 2021

This PR is for prometheus/prometheus#8932. After think about the issue, my solution is divide into two steps.

  1. Use the openMetricsParser located in https://github.com/prometheus/prometheus/tree/main/pkg/textparse to parse the text exchange format into the MetricFamily map . this step is implemented in this PR.
  2. Use https://github.com/prometheus/client_golang/blob/master/prometheus/testutil/promlint/promlint.go promlint to check the metric foramt. If the first step is correct, i'll fastly plan to implement this.

My concern is that, firstly as the openMetricsParser is located in github.com/prometheus/prometheus/ , there may be some hidden circular import problem, although i have tested it works. Secondly, I may be totally wrong about the right direction for solving this issue. i'm very happy to hear from any advices:)!

zhangxiaoyu and others added 3 commits June 17, 2021 23:28
@ide-rea ide-rea closed this Jun 18, 2021
@ide-rea ide-rea deleted the add-openmetrics-parser branch June 18, 2021 05:33
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.

1 participant