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
refactor: stats package #2489
refactor: stats package #2489
Conversation
Codecov ReportBase: 40.54% // Head: 41.36% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## master #2489 +/- ##
==========================================
+ Coverage 40.54% 41.36% +0.82%
==========================================
Files 174 175 +1
Lines 36237 36266 +29
==========================================
+ Hits 14691 15003 +312
+ Misses 20627 20326 -301
- Partials 919 937 +18
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
ddc8e4f
to
c036621
Compare
d697f80
to
da1426f
Compare
da1426f
to
65bd41d
Compare
65bd41d
to
e1d860e
Compare
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.
Amazing work on the tests, approved with some minor comments
e1d860e
to
4f095f6
Compare
06d8608
to
a8b1ab1
Compare
Description
Refactoring the stats package and introducing the following improvements:
stats.Stats
instances (including the default, singleton instance). No more global variables.Stats.Start
&Stats.Stop
for controlling the component's lifecycle. During tests, the default stats instance is initialised, but not started.Measurement
(fkaRudderStats
) instances created before theStats
instance was able to successfully create a statsd client remained muted in the previous implementation. A special test case verifies the correct behaviour (see stats_internal_test.go).Notion Ticket
Link
Security