Yair Zaslavsky has posted comments on this change. Change subject: engine : CommandExecutor should handle exception in CallBackMethods ......................................................................
Patch Set 1: (1 comment) http://gerrit.ovirt.org/#/c/30463/1/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/tasks/CommandExecutor.java File backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/tasks/CommandExecutor.java: Line 66: iterator.remove(); Line 67: break; Line 68: case SUCCEEDED: Line 69: try { Line 70: callBack.onSucceeded(cmdId, coco.getChildCommandIds(cmdId)); in SUCCEEDED yo don't need to change the status to FAILED? if you can consider this, then you can rewrite this code like try { .... switch (status) .... .. catch (Exception ex) { coco.retrieveCommand(cmdId).setCommandStatus(CommandStatus.FAILED); log.errorFormat(....) } of course you will need to set proper logging messages, like, in the errorFormat have a parameter of the method that failed. Line 71: } catch (Exception ex) { Line 72: log.errorFormat("Error invoking onSucceeded for SUCCEEDED command {0}", cmdId.toString()); Line 73: } Line 74: coco.updateCallBackNotified(cmdId); -- To view, visit http://gerrit.ovirt.org/30463 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I06b82f29ac31fd09903d76f87e839d8ac32ef1e1 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Ravi Nori <rn...@redhat.com> Gerrit-Reviewer: Greg Padgett <gpadg...@redhat.com> Gerrit-Reviewer: Oved Ourfali <oourf...@redhat.com> Gerrit-Reviewer: Yair Zaslavsky <yzasl...@redhat.com> Gerrit-Reviewer: automat...@ovirt.org Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches