-
-
Notifications
You must be signed in to change notification settings - Fork 221
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Use package local metrics #1578
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1578 +/- ##
==========================================
+ Coverage 93.88% 93.91% +0.03%
==========================================
Files 78 79 +1
Lines 6361 5078 -1283
==========================================
- Hits 5972 4769 -1203
+ Misses 300 218 -82
- Partials 89 91 +2 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I did this PR as an example of the re-architecture. I'm happy to contribute more improvements. |
Looks like the end to end test for metrics failed though, so it might now fully work at the moment. EDIT: from the logs, the missing metrics match the changed ones:
|
Ahh, yes, this is because Also because it's not created by the The simplest solution would be to use the default registry. |
1ce9a01
to
1742dce
Compare
Improve performance of metrics by moving them to the package that needs them. This reduces the overhead to a simple atomic increment for basic counters like cache hits/misses. This also uses `promauto` to avoid the second step of having to register metrics. Signed-off-by: SuperQ <superq@gmail.com>
Export the custom metrics registry from the metrics package so it can be used with promauto in other packages. Signed-off-by: SuperQ <superq@gmail.com>
I went another direction and simply exported the registry from the metrics package. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Part 2 (0xERR0R#1578) Improve performance of metrics by moving them to the package that needs them. This reduces the overhead to a simple atomic increment for basic counters like cache hits/misses. This also uses `promauto` to avoid the second step of having to register metrics. Signed-off-by: SuperQ <superq@gmail.com>
Part 2 (0xERR0R#1578) Improve performance of metrics by moving them to the package that needs them. This reduces the overhead to a simple atomic increment for basic counters like cache hits/misses. This also uses `promauto` to avoid the second step of having to register metrics. Signed-off-by: SuperQ <superq@gmail.com>
Part 2 (0xERR0R#1578) Improve performance of metrics by moving them to the package that needs them. This reduces the overhead to a simple atomic increment for basic counters like cache hits/misses. This also uses `promauto` to avoid the second step of having to register metrics. Signed-off-by: SuperQ <superq@gmail.com>
Part 2 (0xERR0R#1578) Improve performance of metrics by moving them to the package that needs them. This reduces the overhead to a simple atomic increment for basic counters like cache hits/misses. This also uses `promauto` to avoid the second step of having to register metrics. Signed-off-by: SuperQ <superq@gmail.com>
Improve performance of metrics by moving them to the package that needs them. This reduces the overhead to a simple atomic increment for basic counters like cache hits/misses. This also uses
promauto
to avoid the second step of having to register metrics.