Yair Zaslavsky has submitted this change and it was merged.
Change subject: core: Refactoring AsyncTaskManager
......................................................................
core: Refactoring AsyncTaskManager
This patch performs the following refactors:
a. Refactors createTask to return an SPMAsyncTask object (SPMAsyncTask is the base class
for tasks)
and not the task Id (guid).
b. Takes out DB related code from the CTOR of SPMAsyncTask.
c. Introduces AsyncTaskUtils to hold some common logic for async tasks
d. Introduces entity IDs and entity type to SPMAsyncTask in order to store entity
association with tasks
Change-Id: Ia820fd378331b1360cb2766feda80d8c2878310e
Signed-off-by: Yair Zaslavsky <yzaslavs(a)redhat.com>
---
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/AddImageFromScratchCommand.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/AsyncTaskManager.java
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CreateCloneOfTemplateCommand.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CreateImageTemplateCommand.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CreateSnapshotCommand.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/HibernateVmCommand.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/MoveOrCopyImageGroupCommand.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RemoveImageCommand.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RemoveSnapshotSingleDiskCommand.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RemoveTemplateSnapshotCommand.java
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RestoreFromSnapshotCommand.java
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/SPMAsyncTask.java
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/VmCommand.java
A
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/tasks/AsyncTaskUtils.java
M backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dao/AsyncTaskDAO.java
M
backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dao/AsyncTaskDAODbFacadeImpl.java
M
backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/AsyncTaskDAOTest.java
M backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/FixturesTool.java
M backend/manager/modules/dal/src/test/resources/fixtures.xml
20 files changed, 338 insertions(+), 159 deletions(-)
Approvals:
Yair Zaslavsky: Verified; Looks good to me, approved
--
To view, visit
http://gerrit.ovirt.org/5986
To unsubscribe, visit
http://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ia820fd378331b1360cb2766feda80d8c2878310e
Gerrit-PatchSet: 16
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Yair Zaslavsky <yzaslavs(a)redhat.com>
Gerrit-Reviewer: Maor Lipchuk <mlipchuk(a)redhat.com>
Gerrit-Reviewer: Michael Kublin <mkublin(a)redhat.com>
Gerrit-Reviewer: Yair Zaslavsky <yzaslavs(a)redhat.com>