Change in ovirt-engine[master]: restapi: Adjust display details when adding or updating VMs

juan.hernandez at redhat.com juan.hernandez at redhat.com
Tue May 12 08:34:06 UTC 2015


Juan Hernandez has submitted this change and it was merged.

Change subject: restapi: Adjust display details when adding or updating VMs
......................................................................


restapi: Adjust display details when adding or updating VMs

A previous change modifed the way the display information is populated
to support the new concept of "graphics devices". But this change didn't
take into account that the display information needs to be adjusted for
backwards compatibility not only when retrieving VMs, but also when
adding or modifying them, as those operations also return the
representation of the VM. As a result when a VM is added or updated the
display type field isn't populated and that casuses issues for some
clients that expect this field. In particular this breaks the "rbovirt"
Ruby client. This patch changes the RESTAPI so that the display
adjustment is also performed when adding or updating VMs.

Change-Id: I35c8d28b9278294f780b073ee173520d501797f8
Related: https://bugzilla.redhat.com/1033547
Related: https://gerrit.ovirt.org/35281
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/BackendTemplateResource.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/BackendTemplatesResource.java
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/test/java/org/ovirt/engine/api/restapi/resource/BackendTemplateResourceTest.java
M backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/BackendTemplatesBasedResourceTest.java
M backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/BackendTemplatesResourceTest.java
M backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/BackendVmResourceTest.java
M backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/BackendVmsResourceTest.java
9 files changed, 101 insertions(+), 51 deletions(-)

Approvals:
  Tomas Jelinek: Looks good to me, but someone else must approve
  Juan Hernandez: Verified; Looks good to me, approved
  Jenkins CI: Looks good to me, but someone else must approve



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

Gerrit-MessageType: merged
Gerrit-Change-Id: I35c8d28b9278294f780b073ee173520d501797f8
Gerrit-PatchSet: 3
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: Tomas Jelinek <tjelinek at redhat.com>
Gerrit-Reviewer: automation at ovirt.org



More information about the Engine-commits mailing list