-
Notifications
You must be signed in to change notification settings - Fork 216
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
Most or all metrics exported by Retina should be counters, not gauges #237
Comments
I'm going to open a PR to address this in the |
…orward module's packet and byte counters
@rbtr Could you assign this to me? I opened #238, but I need some help with figuring out how to build Retina locally: #238 (comment). |
just look at these metrics recently and thought of this issue. The reason why we are doing gauges and not counters, even though these metrics supposed to be only ever increasing, is that because we are doing snapshots of the bpf map periodically and |
# Description As title. Closes #237. Also did a bunch of refactoring + removing unused metrics ## Related Issue If this pull request is related to any issue, please mention it here. Additionally, make sure that the issue is assigned to you before submitting this pull request. ## Checklist - [ ] I have read the [contributing documentation](https://retina.sh/docs/contributing). - [ ] I signed and signed-off the commits (`git commit -S -s ...`). See [this documentation](https://docs.github.com/en/authentication/managing-commit-signature-verification/about-commit-signature-verification) on signing commits. - [ ] I have correctly attributed the author(s) of the code. - [ ] I have tested the changes locally. - [ ] I have followed the project's style guidelines. - [ ] I have updated the documentation, if necessary. - [ ] I have added tests, if applicable. ## Screenshots (if applicable) or Testing Completed Please add any relevant screenshots or GIFs to showcase the changes made. ## Additional Notes Add any additional notes or context about the pull request here. --- Please refer to the [CONTRIBUTING.md](../CONTRIBUTING.md) file for more information on how to contribute to this project.
Describe the bug
Retina is currently exporting gauge-type metrics in its modules (e.g. forward.go, drops.go. Since these metrics only go up (or are reset to 0), they should be counters. This is important since a metric type different from the metric's semantical meaning can break the implicit contract and assumptions that people make when querying the data.
From Prometheus documentation:
To Reproduce
N/A
Expected behavior
N/A
Screenshots
N/A
Platform (please complete the following information):
N/A
Additional context
N/A
The text was updated successfully, but these errors were encountered: