Change in ovirt-engine[ovirt-engine-3.5]: core: improve exception handling on run vm

tnisan at redhat.com tnisan at redhat.com
Thu Dec 18 10:05:44 UTC 2014


Tal Nisan has submitted this change and it was merged.

Change subject: core: improve exception handling on run vm
......................................................................


core: improve exception handling on run vm

In case an exception is thrown when calling the 'create' verb in VDSM
and there is no point to retry to run the VM on other host, we used to
just re-throw the exception in RunVmCommand to prevent the rerun
mechanism from taking place.

The problem is that this way the pending resources were not cleared
in this flow. The solution is to improve the error handling:
1. If Done/exists exception was thrown, we call the reportCompleted to
decrease the pending resources
2. If VDS_NETWORK_ERROR/PROVIDER_FAILURE exception was thrown, we call
the runningFailed to decrease the pending resources (in this case, the
VM should be treated as if it went down, we should remove its
stateless snapshot if such snapshot exists for example).

Change-Id: Iee3bdb65ca58c49de65770d4e9cf9435bbbe5070
Bug-Url: https://bugzilla.redhat.com/1174817
Signed-off-by: Arik Hadas <ahadas at redhat.com>
---
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RunVmCommand.java
1 file changed, 4 insertions(+), 3 deletions(-)

Approvals:
  Shahar Havivi: Looks good to me, approved
  Arik Hadas: Verified



-- 
To view, visit http://gerrit.ovirt.org/36245
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iee3bdb65ca58c49de65770d4e9cf9435bbbe5070
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: ovirt-engine-3.5
Gerrit-Owner: Arik Hadas <ahadas at redhat.com>
Gerrit-Reviewer: Arik Hadas <ahadas at redhat.com>
Gerrit-Reviewer: Shahar Havivi <shavivi at redhat.com>
Gerrit-Reviewer: Tal Nisan <tnisan at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server



More information about the Engine-commits mailing list