-
Notifications
You must be signed in to change notification settings - Fork 372
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
Fix the threshold telemetry issue #1394
Conversation
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.
This isn't the right way to fix this problem. Move computation of thresholds into the CGroup constructor, so that self.threshold is present even if CGroup.set_limits() is never called for a particular instance. That will make the original code up in CGroupsTelemetry work under all circumstance. Much smaller change, no duplication of code.
ac3803a
to
91a3371
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.
This is looking a lot better. With the suggested change to the new class constructor, I think you've got a nice solution here.
91a3371
to
764f578
Compare
764f578
to
4843d49
Compare
6875558
to
133f706
Compare
133f706
to
052c34c
Compare
* Changed local variable name and added traceback for exthandler failures (#1392) * Changed local variable name and added traceback * Changing the traceback location * Fix the threshold telemetry issue (#1394) * Adding the get_limits call within the collect_all_tracked call * Added tests for threshold * Send events when extensions fail to complete operation (#1397) * Bumping up the version to 2.2.34
Description
Earlier the thresholds were being assigned during the set_cgroups_limits (and being maintained in the Cgroup class, and member of _tracked in CGroupTelemetry). The monitor thread wasn't picking up the data and we were seeing
2018/11/07 21:18:42.654547 WARNING ExtHandler Monitor: failed to collect Cgroups performance metrics: 'NoneType' object has no attribute '__getitem__'
.This change now explicitly updates the
limits[cgroup_name]
dictionary, which is returned by thecollect_all_tracked()
.Issue #1395, also does half work for #1363
PR information
Quality of Code and Contribution Guidelines