Bug 1039045

Summary: Start process form doesn't show exception
Product: [Retired] JBoss BPMS Platform 6 Reporter: Kris Verlaenen <kverlaen>
Component: Business CentralAssignee: Mauricio Salatino <msalatin>
Status: CLOSED CURRENTRELEASE QA Contact: Zuzana Krejčová <zkrejcov>
Severity: high Docs Contact:
Priority: high    
Version: 6.0.0CC: lpetrovi, mbaluch, rrajasek
Target Milestone: CR1   
Target Release: 6.0.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-08-06 20:10:44 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Kris Verlaenen 2013-12-06 13:03:04 UTC
When you start a process using a process form, and starting the process results in some exception (and thus rollback of the request), the start form does not show any information.  Basically nothing happens (it seems as if the click simply didn't have any effect), and the form doesn't close. The exception is shown in the server log however.

The user should be notified the request was unsuccesful (with error message).

To reproduce, create a process with Start -> Email Task -> End but don't configure the work item handler for Email.  This will result in a "org.drools.core.WorkItemHandlerNotFoundException: Could not find work item handler for Email" when starting the process.  After successfully deploying the process, using the process form to start the process however doesn't show any error message to the user.

Comment 1 Mauricio Salatino 2013-12-09 10:36:48 UTC
Fixed in 6.0.x -> http://github.com/droolsjbpm/jbpm-console-ng/commit/89ec6feaf

This fix also covers the same case but when a task is completed and the next node in the process fails. So both scenarios will be covered:
1) Start -> Email Task -> End
2) Start -> User Task -> Email Task -> End

We currently don't have any way to display the error besides the Problems Panel (which is authoring related) and the Notifications Box (non persistent). 
For now the fix is showing a Notification Box with the error, but the fix is flexible enough to be ported to a more serious error logging mechanism (like UDC) in the near future. I would prefer to integrate UDC/Inbox instead of adding a custom popup to show the runtime errors.

Comment 2 Mauricio Salatino 2013-12-11 09:15:27 UTC
Sorry, I've copied the wrong commit link, here is the correct one: https://github.com/droolsjbpm/jbpm-console-ng/commit/e54f04aeafda52b18b810798d3166f29c3bb587f

Comment 5 Zuzana Krejčová 2014-01-07 16:12:43 UTC
(In reply to Mauricio Salatino from comment #1)
> This fix also covers the same case but when a task is completed and the next
> node in the process fails. So both scenarios will be covered:
> 1) Start -> Email Task -> End
> 2) Start -> User Task -> Email Task -> End

Tested with ER7.
The first scenario works, the second one is a bit more problematic.
In the second scenario, I cannot complete the task and I get no notification.

Also, if I go to process instances and view the instance model, every opening or closing of the instance details panel results in errors in server log. This hasn't happened with ER5. It also won't happen if you don't open the instance model.

ERROR [stderr] (...) context [anonymous] 6175:12 attribute includedo isn't defined
INFO  [org.jbpm.designer.web.preprocessing.impl.JbpmPreprocessingUnit] (...) Created file:/home/zkrejcov/jboss-eap-6.1.1/standalone/deployments/business-central.war/org.kie.workbench.KIEWebapp/stencilsets/bpmn2.0jbpm/bpmn2.0jbpm.json
INFO  [org.jbpm.designer.web.preprocessing.impl.JbpmPreprocessingUnit] (...) Created file:/home/zkrejcov/jboss-eap-6.1.1/standalone/deployments/business-central.war/org.kie.workbench.KIEWebapp/stencilsets/bpmn2.0jbpm/view/activity/workitems/ReadOnlyService.svg
ERROR [stderr] (...) org.uberfire.java.nio.file.FileSystemNotFoundException
ERROR [stderr] (...) 	at org.uberfire.java.nio.fs.jgit.JGitFileSystemProvider.getPath(JGitFileSystemProvider.java:607)
...
WARN  [org.jboss.solder.exception.control.log] (...) No handlers found for exception java.lang.IllegalArgumentException: java.io.FileNotFoundException: /home/zkrejcov/jboss-eap-6.1.1/standalone/deployments/business-central.war/org.kie.workbench.KIEWebapp/stencilsets/bpmn2.0jbpm/stencilset/org.jbpm.designer.jBPMDesigner/stencilsets/bpmn2.0jbpm/bpmn2.0jbpm.json (No such file or directory)
ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/business-central].[StencilSetServiceServlet]] (...) JBWEB000236: Servlet.service() for servlet StencilSetServiceServlet threw exception: java.lang.IllegalArgumentException: java.io.FileNotFoundException: /home/zkrejcov/jboss-eap-6.1.1/standalone/deployments/business-central.war/org.kie.workbench.KIEWebapp/stencilsets/bpmn2.0jbpm/stencilset/org.jbpm.designer.jBPMDesigner/stencilsets/bpmn2.0jbpm/bpmn2.0jbpm.json (No such file or directory)
	at org.jbpm.designer.web.stencilset.impl.LocalStencilSetImpl.getResourceContents(LocalStencilSetImpl.java:46) [jbpm-designer-backend-6.0.1-redhat-2.jar:6.0.1-redhat-2]
...
Caused by: java.io.FileNotFoundException: /home/zkrejcov/jboss-eap-6.1.1/standalone/deployments/business-central.war/org.kie.workbench.KIEWebapp/stencilsets/bpmn2.0jbpm/stencilset/org.jbpm.designer.jBPMDesigner/stencilsets/bpmn2.0jbpm/bpmn2.0jbpm.json (No such file or directory)
...

Comment 7 Mauricio Salatino 2014-01-09 20:18:18 UTC
Second scenario Fixed in 6.0.x: https://github.com/droolsjbpm/jbpm-console-ng/commit/36e7dba58c4938ee53c9513eb76f979d9ade193e

Comment 8 Zuzana Krejčová 2014-01-26 15:32:36 UTC
Verified with CR2.