Change in ovirt-engine[master]: core: Verify that the VM exists when returning callback

Code Review gerrit at ovirt.org
Tue Aug 8 19:57:43 UTC 2017


>From Allon Mureinik <amureini at redhat.com>:

Allon Mureinik has submitted this change and it was merged. ( https://gerrit.ovirt.org/80351 )

Change subject: core: Verify that the VM exists when returning callback
......................................................................


core: Verify that the VM exists when returning callback

It seems that there are use cases where a merge operation fails, leaving
a step in ACTIVE state in the command_entities table. However, at
some point, the VM is deleted. In this case, i.e. as long as the failed
step is ACTIVE, engine restart fails because we will be looking for a VM
that doesn't exist anymore and failing on NPE. In this patch, a
protective check is added in order not to fail on NPE when restarting
the engine and a warning is added to the log asking the user to cleanup
the command_entities table.

Change-Id: Ia49bd24da914f36f09241feae8875055ea1dd27a
Bug-Url: https://bugzilla.redhat.com/1477042
Signed-off-by: Ala Hino <ahino at redhat.com>
---
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/snapshots/RemoveSnapshotCommand.java
1 file changed, 8 insertions(+), 1 deletion(-)

Approvals:
  Jenkins CI: Passed CI tests
  Allon Mureinik: Looks good to me, approved
  Ala Hino: Verified



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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia49bd24da914f36f09241feae8875055ea1dd27a
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Ala Hino <ahino at redhat.com>
Gerrit-Reviewer: Ala Hino <ahino at redhat.com>
Gerrit-Reviewer: Allon Mureinik <amureini at redhat.com>
Gerrit-Reviewer: Daniel Erez <derez at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: gerrit-hooks <automation at ovirt.org>


More information about the Engine-commits mailing list