Change in ovirt-engine[ovirt-engine-4.0]: core: acquire vm lock on RestoreStatelessVm
piotr.kliczewski at gmail.com
piotr.kliczewski at gmail.com
Fri Jun 24 14:31:39 UTC 2016
Piotr Kliczewski has submitted this change and it was merged.
Change subject: core: acquire vm lock on RestoreStatelessVm
......................................................................
core: acquire vm lock on RestoreStatelessVm
RestoreStatelessVm calls two commands:
1. UpdateVmVersion
2. RestoreAllSnapshots
Both used to take exclusive lock on the VM.
Change I870ef6 modified UpdateVmVersion so it will not
acquire the VM lock when it is called by RestoreStatelessVm
but that's because we assume RestoreStatelessVm locked the
VM which is not always the case.
So this patch changes RestoreStatelessVm to lock the VM.
It is safe to do since UpdateVmVersion and RestoreAllSnapshots
used to do it later in the control flow as well. This lock is
passed to RestoreAllSnapshot so it doesn't try to lock the VM
as well.
Change-Id: I3e52fafa8fcb1976c309e5ea79227e9dc1a3c01c
Bug-Url: https://bugzilla.redhat.com/1346270
Signed-off-by: Arik Hadas <ahadas at redhat.com>
---
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RestoreStatelessVmCommand.java
1 file changed, 18 insertions(+), 0 deletions(-)
Approvals:
Piotr Kliczewski: Passed CI tests
Shahar Havivi: Looks good to me, approved
Arik Hadas: Verified
--
To view, visit https://gerrit.ovirt.org/59690
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I3e52fafa8fcb1976c309e5ea79227e9dc1a3c01c
Gerrit-PatchSet: 3
Gerrit-Project: ovirt-engine
Gerrit-Branch: ovirt-engine-4.0
Gerrit-Owner: Arik Hadas <ahadas at redhat.com>
Gerrit-Reviewer: Arik Hadas <ahadas at redhat.com>
Gerrit-Reviewer: Liron Aravot <laravot at redhat.com>
Gerrit-Reviewer: Piotr Kliczewski <piotr.kliczewski at gmail.com>
Gerrit-Reviewer: Shahar Havivi <shavivi at redhat.com>
Gerrit-Reviewer: Shmuel Leib Melamud <smelamud at redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation at ovirt.org>
More information about the Engine-commits
mailing list