Change in ovirt-engine[master]: restapi: Add V3 support for disks detail

juan.hernandez at redhat.com juan.hernandez at redhat.com
Tue Jul 26 07:23:07 UTC 2016


Juan Hernandez has submitted this change and it was merged.

Change subject: restapi: Add V3 support for disks detail
......................................................................


restapi: Add V3 support for disks detail

Version 3 of the API supports a `detail` parameter that can be used to
include inline details into certain objects. In particular it can be
used to request details about the disks of a virtual machine:

  GET /ovirt-engine/api/vms
  Version: 3
  Accept: application/xml; detail=disks

This capability has been removed in version 4 of the API, but needs to
be preserved in version 3, and it works for all the objects that it used
to work, except for disks, because the "disks" collection has been
replaced with "diskattachments".

To fix this issue this patch moves the logic that handles the "detail"
parameter to the V3 compatibility layer, where the "disks" collection
still exists.

Change-Id: Icac0bea3503b542e60edf61fad5da0a1af9bac19
Bug-Url: https://bugzilla.redhat.com/1358860
Signed-off-by: Juan Hernandez <juan.hernandez at redhat.com>
---
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/BackendVmResource.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/BackendVmsResource.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/helpers/V3VmHelper.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/servers/V3VmServer.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/servers/V3VmsServer.java
5 files changed, 51 insertions(+), 17 deletions(-)

Approvals:
  Ori Liel: Looks good to me, approved
  Juan Hernandez: Verified
  Jenkins CI: Passed CI tests



-- 
To view, visit https://gerrit.ovirt.org/61260
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Icac0bea3503b542e60edf61fad5da0a1af9bac19
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Juan Hernandez <juan.hernandez at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Juan Hernandez <juan.hernandez at redhat.com>
Gerrit-Reviewer: Ori Liel <oliel at redhat.com>
Gerrit-Reviewer: Tal Nisan <tnisan at redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation at ovirt.org>



More information about the Engine-commits mailing list