[PATCH 18/19] src: add constants for domain stats 'dirtyrate.' parameters

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Contrary to most APIs returning typed parameters, there are no constants
defined for the domain stats data keys. This is was because many of the
keys needs to be dynamically constructed using one or more array index
values.

It is possible to define constants while still supporting dynamic
array indexes by simply defining the prefixes and suffixes as constants.
The consuming code can then combine the constants with array index
value.

With this approach, it is practical to add constants for the domain stats
API keys.

Signed-off-by: Daniel P. Berrangé <berrange@xxxxxxxxxx>
---
 src/libvirt-domain.c | 17 -----------------
 1 file changed, 17 deletions(-)

diff --git a/src/libvirt-domain.c b/src/libvirt-domain.c
index 02fee7b5b9..aaa44ed3ef 100644
--- a/src/libvirt-domain.c
+++ b/src/libvirt-domain.c
@@ -12324,23 +12324,6 @@ virConnectGetDomainCapabilities(virConnectPtr conn,
  *     The VIR_DOMAIN_STATS_DIRTYRATE_* constants define the known typed
  *     parameter keys.
  *
- *     "dirtyrate.calc_status" - the status of last memory dirty rate calculation,
- *                               returned as int from virDomainDirtyRateStatus
- *                               enum.
- *     "dirtyrate.calc_start_time" - the start time of last memory dirty rate
- *                                   calculation as long long.
- *     "dirtyrate.calc_period" - the period of last memory dirty rate calculation
- *                               as int.
- *     "dirtyrate.megabytes_per_second" - the calculated memory dirty rate in
- *                                        MiB/s as long long. It is produced
- *                                        only if the calc_status is measured.
- *     "dirtyrate.calc_mode" - the calculation mode used last measurement, either
- *                             of these 3 'page-sampling,dirty-bitmap,dirty-ring'
- *                             values returned.
- *     "dirtyrate.vcpu.<num>.megabytes_per_second" - the calculated memory dirty
- *                                                   rate for a virtual cpu as
- *                                                   unsigned long long.
- *
  * VIR_DOMAIN_STATS_VM:
  *     Return hypervisor-specific statistics. Note that the naming and meaning
  *     of the fields is entirely hypervisor dependent.
-- 
2.48.1




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux