-
Notifications
You must be signed in to change notification settings - Fork 814
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
Make histogram aggregates & percentiles configurable globally #1303
Conversation
299bbeb
to
24bcaf0
Compare
@@ -605,6 +617,10 @@ def __init__(self, hostname, interval=1.0, expiry_seconds=300, formatter=None, r | |||
'ms': Histogram, | |||
's': Set, | |||
} | |||
self.histogram_aggregates = histogram_aggregates\ |
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.
That should probably be in the Aggregator class so you don't have to duplicate it in all its subclasses.
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.
That was my first approach, before realizing that no metric specific (say Histograms for instance) code was in this class, I can put that here but I find it lacking consistency a bit. Maybe I should just refactor more things 😒
e84a996
to
1cd1c08
Compare
@remh this is should be ready for final review hopefully (allowing per metric type config to be passed, with no special case for histograms) |
@@ -42,7 +43,7 @@ def testBadPidFile(self): | |||
|
|||
p = PidFile('test', pid_dir) | |||
path = p.get_path() | |||
self.assertEquals(path, "/tmp/test.pid") | |||
self.assertEquals(path, os.path.join(os.environ.get('TMPDIR', '/tmp'), 'test.pid')) |
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.
even better:
self.assertEquals(path, os.path.join(tempfile.gettempdir(), 'test.pid')
1cd1c08
to
9b8d250
Compare
Make histogram aggregates & percentiles configurable globally
Changes Unknown when pulling 9b8d250 on leo/histogram_min into * on master*. |
No description provided.