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

Initialize counter metrics upon declaration #36

Open
VitorTrin opened this issue Nov 25, 2019 · 2 comments
Open

Initialize counter metrics upon declaration #36

VitorTrin opened this issue Nov 25, 2019 · 2 comments

Comments

@VitorTrin
Copy link

Declaring a counter does not mean it exists, as it will only have a value after the first inc. So, the fist time a counter is bumped it goes from not existing to 1, which makes it hard to create alert expressions. I propose that we manually assure the metric exists, (It can be done by doing a inc by 0) so we have stable counters.

Maybe this should be adressed by prometheus_ex? What you think?

@deadtrickster
Copy link
Owner

I think not only about alerts but also restarts... Maybe default value?

@VitorTrin
Copy link
Author

What would a restart do? I haven't tested that yet.

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

No branches or pull requests

2 participants