Change in ovirt-engine[master]: core: MoveOrCopyDiskCommand - do not pass same parameters in...

Liron Aravot has submitted this change and it was merged. Change subject: core: MoveOrCopyDiskCommand - do not pass same parameters instance ...................................................................... core: MoveOrCopyDiskCommand - do not pass same parameters instance The parameters instance of each command contains information that is unique to the command (for example - the command id). In MoveOrCopyDiskCommand the parameters of the command are passed to to child command which is problematic - the infra doesn't support that and it causes the endAction() of the wrong command to be executed, for entities to stay locked and so on. This patch solves that by adding a copy constructor to the parameters class hirerchy excluding the base parameters class that contains command specific information. That is the taken approach to minimize the risk of influecing one of the command usages as we'll backport this change. Later on we can remove the copy constructor and just create the child parameters manually without relying on the fact that they are of the same type of the parent command. Change-Id: I9b127231c8fb8a416d1861c2a6395fd2c0966c6b Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1282693 Signed-off-by: Liron Aravot <laravot@redhat.com> --- M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/MoveOrCopyDiskCommand.java M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/ImagesActionsParametersBase.java M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/ImagesContainterParametersBase.java M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/MoveOrCopyImageGroupParameters.java M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/StorageDomainParametersBase.java M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/StoragePoolParametersBase.java 6 files changed, 80 insertions(+), 29 deletions(-) Approvals: Liron Aravot: Verified; Looks good to me, approved; Passed CI tests -- To view, visit https://gerrit.ovirt.org/48633 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: merged Gerrit-Change-Id: I9b127231c8fb8a416d1861c2a6395fd2c0966c6b Gerrit-PatchSet: 4 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Liron Aravot <laravot@redhat.com> Gerrit-Reviewer: Allon Mureinik <amureini@redhat.com> Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Liron Aravot <laravot@redhat.com> Gerrit-Reviewer: Tal Nisan <tnisan@redhat.com> Gerrit-Reviewer: gerrit-hooks <automation@ovirt.org>
participants (1)
-
laravot@redhat.com