Change in ovirt-engine[ovirt-engine-3.6]: core: acquire vm lock on RestoreStatelessVm
tnisan at redhat.com
tnisan at redhat.com
Sun Jun 26 07:42:19 UTC 2016
Tal Nisan 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/1348950
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:
Shahar Havivi: Looks good to me, approved
Jenkins CI: Passed CI tests
Arik Hadas: Verified
--
To view, visit https://gerrit.ovirt.org/59698
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-3.6
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: Tal Nisan <tnisan at redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation at ovirt.org>
More information about the Engine-commits
mailing list