Closed Rebits closed 1 month ago
In a meeting with @Rebits some questions about the issue were clarified. These inquiries were the following:
Refactored current script to make use of "advanced" type hinting (making use of the typing module).
Started modularization of Monitor and different logging classes.
Researched references made to the Monitor class, only found wazuh_metrics.py
.
Extensive research about PEP 8 – Style Guide for Python Code
.
Continued modularization of Monitor and Logging classes and addded type hinting for those last ones.
Increased functionality of Monitor class to track disk usage instead of creating another module because it seems appropiate in this situation since it already monitors memory size, swap, file descriptors, read and write operations and bytes read and written. As discussed with @Rebits some of the logic of some methods has to be modified not to depend on hardcoded values, or at least specify the available values that can be used.
Moved ETA to 21/09/2024 to allow final review
On hold due to #25203
On hold due to #25270
Refactoring the existing script that makes use of the module for resource monitoring (the script that is called).
On hold due to 4.9.0 RC 2 Footprint
Worked on the creation of unit tests for the partition usage module.
On hold due to jenkins 6919 Even though the aforementioned issue has lower priority it's planned for the next release so it has precedence over this one.
Created branch: enhancement/24683-process-resource-monitoring
Associated PR: https://github.com/wazuh/wazuh-qa/pull/5747
Addressed the changes requested.
Working on the changes requested in the PR (https://github.com/wazuh/wazuh-qa/pull/5747#discussion_r1775635279)
Description
Develop a monitoring class to collect process data within the Wazuh environment. This class should track various aspects of process performance, such as CPU usage, memory consumption, etc. The data collected will be used to analyze and optimize the performance of the Wazuh agent.
Overview
We are considering using existing tools for this task, specifically the QA Monitor class. This issue involves checking the current status of the monitor class, fixing any pending bugs, and adding any new capabilities needed to fulfill the requirements.
Functional requirements
Tasks
Validation