Change in ovirt-engine[master]: core: fix import vm from vmware as clone

ahadas at redhat.com ahadas at redhat.com
Wed Dec 30 08:55:34 UTC 2015


Arik Hadas has submitted this change and it was merged.

Change subject: core: fix import vm from vmware as clone
......................................................................


core: fix import vm from vmware as clone

This patch fixes the functionality of import-as-clone from VMware.
The problem was that on import-as-clone we generate new ID, but
in the ImportFromExternalProviderCommand we never used the generated
ID.

The solution is composed of 2 parts:

1. To move the getters for VM-ID that reside in ImportVmCommand and
knows to return the right ID, also for the import-as-clone case, to
ImportVmCommandBase so they will be shared with the command
ImportFromExternalProviderCommand as well.

2. We need the parameters to store the ID of the VM in two fields:
getVm().getId() and getVmId(). Instead of setting it manually, we
now call the constructor of ImportVmParameters that does the trick.

Change-Id: I32dfe891c6168d3c1d522e2588ae9e02d82b9de3
https://bugzilla.redhat.com/1294501
Signed-off-by: Arik Hadas <ahadas at redhat.com>
---
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/ImportVmCommand.java
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/ImportVmCommandBase.java
M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/ImportVmFromExternalProviderParameters.java
M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/ImportVmFromOvaParameters.java
M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/ImportVmParameters.java
M frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/vms/ImportVmFromOvaModel.java
M frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/vms/ImportVmFromVmwareModel.java
7 files changed, 47 insertions(+), 27 deletions(-)

Approvals:
  Shahar Havivi: Looks good to me, approved
  Jenkins CI: Passed CI tests
  Arik Hadas: Verified



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

Gerrit-MessageType: merged
Gerrit-Change-Id: I32dfe891c6168d3c1d522e2588ae9e02d82b9de3
Gerrit-PatchSet: 6
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Arik Hadas <ahadas at redhat.com>
Gerrit-Reviewer: Arik Hadas <ahadas at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Shahar Havivi <shavivi at redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation at ovirt.org>



More information about the Engine-commits mailing list