Change in ovirt-engine[ovirt-engine-4.0]: restapi: Populate V3 snapshot type correctly

oourfali at redhat.com oourfali at redhat.com
Mon Jun 20 12:34:55 UTC 2016


Oved Ourfali has submitted this change and it was merged.

Change subject: restapi: Populate V3 snapshot type correctly
......................................................................


restapi: Populate V3 snapshot type correctly

In version 3 of the API the VmBase#type attribute had two different
meanings, depending on the context: the type of virtual machine (desktop
of server) when used with virtual machines or templates, and the type of
snapshot (regular, active, etc) when sued with snapshots. In version 4
of the API this isn't possible because each attribute has attribute has
exactly one type. To handle that a new `snapshot_type` attribute was
added to the snapshot entity. But the version 3 compatibility layer
didn't take this into account, and as a result the old `type` attribute
wasn't populated. This patch fixes that, so the old `type` attribute is
populated correctly.

Change-Id: I8b50b994533135fbc0a5d924a3df958b4b6cb584
Bug-Url: https://bugzilla.redhat.com/1348138
Signed-off-by: Juan Hernandez <juan.hernandez at redhat.com>
(cherry picked from commit 977aa6a2222d9166bad240d9cef69fe062026043)
---
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3SnapshotInAdapter.java
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/v3/adapters/V3SnapshotOutAdapter.java
2 files changed, 4 insertions(+), 4 deletions(-)

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



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

Gerrit-MessageType: merged
Gerrit-Change-Id: I8b50b994533135fbc0a5d924a3df958b4b6cb584
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: ovirt-engine-4.0
Gerrit-Owner: Juan Hernandez <juan.hernandez at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Juan Hernandez <juan.hernandez at redhat.com>
Gerrit-Reviewer: Oved Ourfali <oourfali at redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation at ovirt.org>



More information about the Engine-commits mailing list