5 Commits

Author SHA1 Message Date
nicolargo
45b3164464 Improve docs and also add min/max/mean for CPU and load 2026-03-07 10:09:24 +01:00
Siddharth Doshi
e306ad24b6 feat(plugin): add generic mmm (min/max/mean) support in base plugin model
Introduce a generic Min/Max/Mean (mmm) mechanism at the plugin model level.

When a field in `fields_description` defines `'mmm': True`, the plugin
automatically generates and maintains the following derived fields:

  <field>_min
  <field>_max
  <field>_mean

The computation is handled in the base plugin model to ensure the
feature is reusable across all plugins. Mean is calculated as a
running mean, and min/max are updated on each refresh cycle.

This implementation:
- Keeps the feature opt-in per field
- Avoids hardcoding logic in individual plugins
- Maintains full backward compatibility
- Preserves existing API v4 response structure
- Ensures no regression in existing behavior

Unit tests have been added to validate correct field generation
and update behavior.
2026-03-01 17:34:33 +05:30
Siddharth Doshi
5248bec5ee Enhance the existing memory plugin to track runtime minimum and maximum memory usage percentage since Glances startup and expose these values through the existing /api/4/mem endpoint. 2026-02-28 14:30:31 +05:30
Ambika Patidar
5eb1f4b794 test: Fix linting issues and trailing whitespace 2026-02-07 00:55:14 +05:30
Ambika Patidar
645841d99a Added test cases for plugins 2026-02-06 17:51:37 +05:30