Arik Hadas has uploaded a new change for review. Change subject: core: fix NPE on failure to run stateless vm ......................................................................
core: fix NPE on failure to run stateless vm Running VM in stateless mode is composed of two parts: the stateless snapshot creation and then running the VM. In the second part we invoke RunVmCommand and ask it to end the operation's job when it is done. The problem was that RunVmCommand didn't get the operation's job, so when it tried to end the job, NPE was thrown and the job's tasks remained unfinished. This problem is solved by passing the operation's job to the inner RunVmCommand. Change-Id: I922b0cfaf9a50de35ec9c2ca6195d5326600ce5a Bug-Url: https://bugzilla.redhat.com/1039507 Signed-off-by: Arik Hadas <[email protected]> --- M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RunVmCommand.java 1 file changed, 1 insertion(+), 0 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/50/22450/1 diff --git a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RunVmCommand.java b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RunVmCommand.java index 7d7cf9c..ab6da1d 100644 --- a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RunVmCommand.java +++ b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RunVmCommand.java @@ -875,6 +875,7 @@ getVmValuesForMsgResolving())); // This is needed in order to end the job upon exextuion of the steps of the child command runStatelessVmCtx.setShouldEndJob(true); + runStatelessVmCtx.setJob(job); // Since run stateless step involves invocation of command, we should set the run stateless vm step as // the "beginning step" of the child command. runStatelessVmCtx.setStep(runStatelessStep); -- To view, visit http://gerrit.ovirt.org/22450 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I922b0cfaf9a50de35ec9c2ca6195d5326600ce5a Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: ovirt-engine-3.3 Gerrit-Owner: Arik Hadas <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
