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

adds /metrics endpoint with prometheus format #55

Merged
merged 1 commit into from Jul 7, 2022

Conversation

michbeck100
Copy link
Collaborator

No description provided.

@benni336
Copy link
Contributor

Hi Michael,

I once did a commit for an JSON-Export. But I put it into it's own export method.
That had the advantage that it was configureable via the config.py and looks more like a "plugin".
But it has also disadvantage: code duplication, and it needs to run on its own port.

I think it would be a nice step to "choose",

  • wether one want one "http text export" leading to sub directories like /json or /metrics and the html export.
  • or wether one want a "plugin style" solution, like http-webserver, mqtt-export, pvOutput and also JSON and Prometheus export.

Just as a remark.

Greetings from Cologne, DE

@michbeck100
Copy link
Collaborator Author

I think the code duplication is a problem. That's why I just used the /metrics endpoint of the http-webserver. I think this does not need any notable resources.

Copy link
Owner

@bohdan-s bohdan-s left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Might change this to /api/v1/ in the future

@bohdan-s bohdan-s merged commit 8258ed5 into bohdan-s:main Jul 7, 2022
@michbeck100 michbeck100 deleted the feature/prometheus-export branch July 8, 2022 05:14
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.

None yet

3 participants