Skip to content
Discussion options

You must be logged in to vote

Proposed Implementation for Resource Usage Monitoring

1. Enhance the ResourceUsage Model

  • Add from_time and to_time fields to track the monitoring period.
  • Include total_disk_read and total_disk_write to capture cumulative disk activity.
  • Ensure fields are optional or have defaults for flexibility.

2. Update the Command to Support Time-Based Metrics

  • Add --until argument to specify the end time for monitoring (format: HH:MM:SS).
  • Add --interval_minutes argument to define the interval for metric collection.
  • Calculate average CPU, memory, and disk usage over the specified period.
  • Store cumulative network and disk activity (sent/received, read/write).

3. Example Command Usage

python manage.py…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by ARYAN-NIKNEZHAD
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
enhancement New feature or request
2 participants