-
Bug
-
Resolution: Done
-
Undefined
-
None
-
None
-
False
-
-
False
-
-
When workflow execution fails and returns a failed response (from the workflow itself) , the returned exception as part of the report is silently ignored.
The following snippet exemplifies the code from an arbitrary workflow that returns a RuntimeException. However, that exception is being ignored and not logged.
catch (Exception e) { return new DefaultWorkReport(WorkStatus.FAILED, workContext, new RuntimeException("some error", e)); }
The same goes for the returned response to a task.
Following the code started from here will show the WorkReport.getError() is never considered.
There is a difference in the behavior between a workflow that fails by throwing an exception to a workflow that failed by adding an exception to the work-report for which the post-processing will be invoked.
The exception can also be added to the task-logs using the new API being added in this PR:
https://github.com/parodos-dev/parodos/pull/368