-
Notifications
You must be signed in to change notification settings - Fork 372
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Start sending additional memory information per process (#1729)
* Adding ResourceUsage Class and Adding ProcessIds in Telemetry * Adding process tests to fetch the processes in cgroup * Sending Resource Metrics for Memory Usage telemetry. * Sending Memory Data for Tracked Processes * Fix proc_statm collection and dictionary formatting * Updating the process_name pattern when sending memory telemetry * Adding the default process_name, process_commandline * Handling inactive cgroups; not send empty values in ExtensionMetricsData - Making it more explicit for Memory cases as well if IOError came. - Adding a filter to make sure not adding entries into Metrics which are marked_for_delete - Tests changes * Fixing the missed test - Changing the memory exceptions. * Review Comments addressed, and clearer exception handling. - cgroups.py - cleaner returns and raises - cgroupstelemetry.py - exception handling when proc_statm for PID fails. - exception.py - cgroup comments fixed - resourceusage.py - raising an exception when failing to get memory info. - monitor.py - reverted the reset_logger changes - test_cgroupstelemetry.py - stray print and mock removed. - test_resourceusage.py - newline and end - test_monitor.py - removed reset_logger changes, and count of metrics fixed. * Making IOError explicit for get_memory_usage_proc_statm & test fixes - resourceusage.py - Propogate IOError(Errno2) above, and for other exceptions, raise ProcessInfoException. - test_resourceusage.py - Add more asserts to check the raising of IOError, ProcessInfoException. * Addressing review comments. - cgroupstelemetry.py - handling of exception thrown by get_proc_*. Also, some variable name refactoring. - resourceusage.py - Bubbling up exceptions in get_proc_* - test_cgroupstelemetry.py - Refactoring variable name. - test_resourceusage.py - Changes in test to test exception bubbling up. * Initializing a new logger for each test here to not conflict with others * Review comments addressed and some refactoring. - test_cgroups.py - Simple refactoring of class setup and asserts fixed for get_tracked_process - resourceusage.py - Comments fixed. - cgroupstelemetry.py - Refactored the strings into class for easy usage. - cgroup.py - Refactoring the controller names strings into class. Also changed get_tracked_processes' return behavior.
- Loading branch information
Showing
14 changed files
with
773 additions
and
401 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.