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 grafana integration #451

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

Add grafana integration #451

wants to merge 1 commit into from

Conversation

plars
Copy link
Contributor

@plars plars commented Jan 24, 2025

Description

Add grafana integration so that (hopefully) it will push the prototype dashboard that shows mostly flask metrics right now.

This is based on the documentation at https://juju.is/docs/sdk/observe-your-charm-with-cos-lite#heading--integrate-with-grafana but I have not had the opportunity to test it yet. It seems to build ok, but that's all I know right now.

Aside from that, I've put this grafana template into a live instance, and it produces some useful data. The one exception that I didn't have time to sort out is the testflinger total jobs. I used a prometheus counter for this, but it can reset to 0 whenever the application restarts (due to upgrades, etc). Prometheus is supposed to have a way of automatically dealing with this, but I haven't sorted out how to make it work correctly so that the data is always monotonically increasing.

Hopefully someone else with much better grafana-fu than I can sort it out. :)

@plars plars force-pushed the grafana-integration branch from 830fc6f to f0c5568 Compare January 24, 2025 23:07
@plars plars requested review from a team and andrejvelichkovski January 24, 2025 23:14
@plars plars marked this pull request as draft January 24, 2025 23:14
@plars
Copy link
Contributor Author

plars commented Jan 24, 2025

unsurprisingly, something more than what I see in the docs at https://juju.is/docs/sdk/observe-your-charm-with-cos-lite#heading--integrate-with-grafana seems to be needed, but I'm about out of time. Hopefully, at the very least, this will be a good starting point with the .json file which can be imported into a grafana dashboard and used as a starting point. Feel free to take whatever you find useful from this and close it whenever you see fit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant