Bug 1132502 - [GUI over REST API gaps] missing GetVmsByDiskGuid
Summary: [GUI over REST API gaps] missing GetVmsByDiskGuid
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine
Version: 3.5.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ovirt-3.6.0-rc
: 3.6.0
Assignee: Juan Hernández
QA Contact: Ori Gofen
URL:
Whiteboard:
Depends On:
Blocks: 1132506
TreeView+ depends on / blocked
 
Reported: 2014-08-21 13:06 UTC by Einav Cohen
Modified: 2016-05-26 01:52 UTC (History)
14 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:
oVirt Team: Storage
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 34695 0 None None None Never
oVirt gerrit 34696 0 master MERGED restapi: Add reference to VM to disks Never

Description Einav Cohen 2014-08-21 13:06:31 UTC
we are missing a way to invoke the GetVmsByDiskGuid query in the REST API. 
this query is being used in the GUI in the 'Disks -> VMs' sub-tab. 

[I assume that this query returns all of the VMs to which a specified Disk is attached]

Comment 1 Juan Hernández 2014-10-31 11:12:28 UTC
Currently the representation of the /disks/{disk:id} resource already supports a "vm" element, intended to contain the reference to the virtual machine that the disk belongs to. In fact this "vm" element is part of the more general "device" entity. Unfortunately this reference is only populated for /vms/{vm:id}/disks collection, which is useless in this case. And even when it is populated it is populated automatically with only one reference, taken from the parent resource. For example, when requesting /vms/123/disks/456 the reference is automatically populated with this:

  <disk>
    <vm id="123"/>
  </disk>

To fix this bug we need to do the following:

1. Change the XML schema so that instead of the "vm" element (or in addition to, in order to preserve backwards compatibility) we have a "vms" element containing potentially multiple "vm" elements.

2. Change the top level disk resource so that the "vms" element is populated invoking the GetVmsByDiskGuid query.

3. Remove the "vm" element, in 4.0.

Comment 2 Ori Gofen 2015-05-10 11:05:41 UTC
verified on ovirt-master3.6

Comment 5 Allon Mureinik 2016-03-10 10:45:14 UTC
RHEV 3.6.0 has been released, setting status to CLOSED CURRENTRELEASE

Comment 6 Allon Mureinik 2016-03-10 10:48:50 UTC
RHEV 3.6.0 has been released, setting status to CLOSED CURRENTRELEASE

Comment 7 Allon Mureinik 2016-03-10 12:05:19 UTC
RHEV 3.6.0 has been released, setting status to CLOSED CURRENTRELEASE


Note You need to log in before you can comment on or make changes to this bug.