+++ This bug was initially created as a clone of Bug #1150071 +++
Description of problem:
API rsdl is missing the "snapshot id" flag in single snapshot preview. This is inconsistent with Rest API which includes the flag
Version-Release number of selected component (if applicable):
rhevm-3.5.0-0.13.beta.el6ev.noarch
vdsm-4.16.5-2.el6ev.x86_64
How reproducible:
always
Steps to Reproduce:
1. Ran a query in Rest API for a single disk snapshot preview
2. The operation failed with a missing snapshot id
3. Need to add the "snapshot id" flag to the api rsdl
Actual results:
snapshot id is missing from the single snapshot preview option in th api rdsl
Expected results:
Add "snapshot id" to the api rdsl
NB! Do not fix by removing the "snapshot id" from the REST API as all the automation tests include this flag
Additional info:
api rdsl output: <<<< ===== snapshot id is missing here! =====
<body><type>Action</type><parameters_set><parameter required="true" type="xs:string"><name>action.snapshot.id</name></parameter><parameter required="false" type="xs:boolean"><name>action.restore_memory</name></parameter><parameter required="false" type="collection"><name>action.disks.disk</name><parameters_set><parameter required="false" type="xs:string"><name>disk.id</name></parameter><parameter required="false" type="xs:string"><name>disk.image_id</name></parameter></parameters_set></parameter></parameters_set></body>
REST API:
<action>
<snapshot id="{snapshot_id}"/>
<restore_memory>true|false</restore_memory>
<disks>
<disk id="{disk_id}">
<image_id>{image_id}</image_id>
<snapshot id="{snapshot_id}"/> <<< ======== THIS IS MISSING in api rsdl!!! ==========
</disk>
</disks>
</action>
--- Additional comment from Juan Hernández on 2014-10-07 08:03:58 EDT ---
I see the snapshot id parameter in the RSDL fragment available in the "additional info" section of the description of the bug:
<body>
<type>Action</type>
<parameters_set>
<parameter required="true" type="xs:string">
<name>action.snapshot.id</name> <== Here it is.
</parameter>
<parameter required="false" type="xs:boolean">
<name>action.restore_memory</name>
</parameter>
...
</parameter_set>
</parameters_set>
</body>
Where is it missing?
--- Additional comment from on 2014-10-22 04:13:25 EDT ---
Hi Juan,
In the RSDL action body like you pasted, there is one place where the snapshot should be entered. but, when actually performing the action, the body is like Kevin pasted:
<action>
<snapshot id="{snapshot_id}"/>
<restore_memory>true|false</restore_memory>
<disks>
<disk id="{disk_id}">
<image_id>{image_id}</image_id>
<snapshot id="{snapshot_id}"/> <<< == THIS IS MISSING from rsdl
</disk>
</disks>
</action>
You can see that it is requested to add the snapshot id inside the disk object.
This is the relevant part from the rsdl:
<parameter required="false" type="collection">
<name>action.disks.disk</name>
<parameters_set>
<parameter required="false" type="xs:string">
<name>disk.id</name>
</parameter>
<parameter required="false" type="xs:string">
<name>disk.image_id</name>
only disk id and image id of that disk are requested in the rsdl (snapshot id isn't but still mandatory to perform this action)
--- Additional comment from Juan Hernández on 2014-10-22 10:35:21 EDT ---
Understood, you are right.
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.
https://rhn.redhat.com/errata/RHBA-2015-0184.html