Francesco Romani has uploaded a new change for review.

Change subject: schema: require vmId in {Exited,Running}VmStats
......................................................................

schema: require vmId in {Exited,Running}VmStats

On http://gerrit.ovirt.org/#/c/37694/3 we were reminded
in an harsh way that vmId must always be present in
the Vm.getStats() output.

One of the problems was that the vmId field was injected
the Vm.getStats() output by API.py, and this value was
not documented in the schema.

So, this patches update the schema to reflect the
reality of the Engine's needs.

Change-Id: Id4ac677f4321277fa274510c5a0b830b09e0b1bd
Related-To: https://bugzilla.redhat.com/1191405
Signed-off-by: Francesco Romani <from...@redhat.com>
---
M vdsm/rpc/vdsmapi-schema.json
1 file changed, 8 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/96/37696/1

diff --git a/vdsm/rpc/vdsmapi-schema.json b/vdsm/rpc/vdsmapi-schema.json
index 93b6691..1d919e8 100644
--- a/vdsm/rpc/vdsmapi-schema.json
+++ b/vdsm/rpc/vdsmapi-schema.json
@@ -6433,6 +6433,8 @@
 #
 # Statistics about a VM that no longer running.
 #
+# @vmId:         The UUID of the Vm
+#
 # @exitCode:     Code indicating whether the VM exit was normal or in error
 #
 # @status:       The current VM status
@@ -6446,8 +6448,9 @@
 # Since: 4.10.0
 ##
 {'type': 'ExitedVmStats',
- 'data': {'exitCode': 'VmExitCode', 'status': 'VmStatus', 'exitMessage': 'str',
-          'exitReason': 'VmExitReason', '*timeOffset': 'int'}}
+ 'data': {'vmId': 'UUID', 'exitCode': 'VmExitCode', 'status': 'VmStatus',
+          'exitMessage': 'str', 'exitReason': 'VmExitReason',
+          '*timeOffset': 'int'}}
 
 ##
 # @VmDiskStats:
@@ -6765,6 +6768,8 @@
 #
 # Statistics for a running virtual machine.
 #
+# @vmId:               The UUID of the Vm
+#
 # @displayPort:        The port in use for unencrypted display data
 #
 # @displaySecurePort:  The port in use for encrypted display data
@@ -6861,7 +6866,7 @@
 # Since: 4.10.0
 ##
 {'type': 'RunningVmStats',
- 'data': {'displayPort': 'uint', 'displaySecurePort': 'uint',
+ 'data': {'vmId': 'UUID', 'displayPort': 'uint', 'displaySecurePort': 'uint',
           'displayType': 'VmDisplayType', 'displayIp': 'str', 'pid': 'uint',
           'vmType': 'VmType', 'kvmEnable': 'bool',
           'network': 'NetworkInterfaceStatsMap',


-- 
To view, visit http://gerrit.ovirt.org/37696
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id4ac677f4321277fa274510c5a0b830b09e0b1bd
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Francesco Romani <from...@redhat.com>
_______________________________________________
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches

Reply via email to