Michael Kublin has submitted this change and it was merged.
Change subject: engine: Removing using of latch all around a code
......................................................................
engine: Removing using of latch all around a code
In engine code has requirements to run couple of simentenious tasks and stuck a main
thread untill they will be finished.
A previous solution was to use a latch, which required to write a same code and keep some
logic for increasing and reducing latch count.
A new solution is to provide a generic way for such problem and to use a standard java api
for
running couple of parallel tasks and waits untill all of them will be finished
Change-Id: I34ffc04f7abf57f3d27322a5615f89d07dee16ef
Signed-off-by: Michael Kublin <mkublin(a)redhat.com>
---
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/GlusterMultipleActionsRunner.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/IsoDomainListSyncronizer.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/MultipleActionsRunner.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/storage/ReconstructMasterDomainCommand.java
R
backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/LatchedRunnableWrapper.java
M
backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/MultiThreadedDAOTest.java
M
backend/manager/modules/utils/src/main/java/org/ovirt/engine/core/utils/SyncronizeNumberOfAsyncOperations.java
D
backend/manager/modules/utils/src/main/java/org/ovirt/engine/core/utils/thread/LatchedRunnableExecutor.java
M
backend/manager/modules/utils/src/main/java/org/ovirt/engine/core/utils/threadpool/ThreadPoolUtil.java
D
backend/manager/modules/utils/src/test/java/org/ovirt/engine/core/utils/thread/LatchedRunnableWrapperTest.java
10 files changed, 136 insertions(+), 320 deletions(-)
Approvals:
Michael Kublin: Verified; Looks good to me, approved
--
To view, visit
http://gerrit.ovirt.org/11037
To unsubscribe, visit
http://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I34ffc04f7abf57f3d27322a5615f89d07dee16ef
Gerrit-PatchSet: 3
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Michael Kublin <mkublin(a)redhat.com>
Gerrit-Reviewer: Allon Mureinik <amureini(a)redhat.com>
Gerrit-Reviewer: Barak Azulay <bazulay(a)redhat.com>
Gerrit-Reviewer: Eli Mesika <emesika(a)redhat.com>
Gerrit-Reviewer: Liron Aravot <laravot(a)redhat.com>
Gerrit-Reviewer: Michael Kublin <mkublin(a)redhat.com>
Gerrit-Reviewer: Ravi Nori <rnori(a)redhat.com>
Gerrit-Reviewer: Shireesh Anjal <sanjal(a)redhat.com>
Gerrit-Reviewer: Yair Zaslavsky <yzaslavs(a)redhat.com>