[jboss-user] [JBoss jBPM] - Problems with Taskforms: forms cannot be found / NullPointer
sebastian.s
do-not-reply at jboss.com
Mon Aug 17 07:35:43 EDT 2009
Hello!
I used the following process to play around with jBPM. Everything worked fine. Lately I added forms to the user tasks. At first just for the first task which is named "request". I could login, open the task and I saw the form. Submitting also worked fine. Afterwards I loggged in as a different user to perform the following tasks and the the form for "hr_review" did not work. Instead an Exception was thrown.
| <?xml version="1.0" encoding="UTF-8"?>
|
| <process description="Urlaubsantrag zum Test der Process Engine" name="demonstration_vacation_request" xmlns="http://jbpm.org/4.0/jpdl" key="demo" version="1">
| <start g="152,6,48,48" name="start1">
| <transition g="-72,-19" name="to request" to="request"/>
| </start>
| <end g="149,456,48,48" name="end1"/>
| <task assignee="mary" form="request.ftl" g="130,87,92,52" name="request">
| <transition g="-49,-21" name="to fork1" to="fork1"/>
| </task>
| <fork g="153,174,48,48" name="fork1">
| <transition g="22,-21" name="to proj_review" to="proj_review"/>
| <transition g="-68,-24" name="to hr_review" to="hr_review"/>
| </fork>
| <task assignee="mike" form="proj_review.ftl" g="236,257,92,52" name="proj_review">
| <transition g="16,-6" name="to exclusive1" to="decision"/>
| </task>
| <java class="Vacation" g="321,349,101,52" method="save" name="save_vacation">
| <transition g="-48,-21" name="to end1" to="end1"/>
| </java>
| <task assignee="alex" form="hr_review.ftl" g="47,257,92,52" name="hr_review">
| <transition g="-105,-13" name="to exclusive1" to="decision"/>
| </task>
| <decision g="155,341,48,48" name="decision">
| <handler class="Evaluation" />
| <transition g="-48,-21" name="to end1" to="end1"/>
| <transition g="-51,-21" name="to save_vacation" to="save_vacation"/>
| </decision>
| </process>
|
| 13:00:08,481 ERROR [[Resteasy]] Servlet.service() for servlet Resteasy threw exc
| eption
| org.jboss.resteasy.spi.UnhandledException: java.lang.RuntimeException: Unexpecte
| d invocation exception: null
| at org.jboss.resteasy.core.SynchronousDispatcher.handleApplicationExcept
| ion(SynchronousDispatcher.java:319)
| at org.jboss.resteasy.core.SynchronousDispatcher.handleException(Synchro
| nousDispatcher.java:230)
| at org.jboss.resteasy.core.SynchronousDispatcher.handleInvokerException(
| SynchronousDispatcher.java:206)
| at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispa
| tcher.java:360)
| at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispa
| tcher.java:173)
| at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.servi
| ce(HttpServletDispatcher.java:93)
| at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.servi
| ce(HttpServletDispatcher.java:68)
| at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
| icationFilterChain.java:290)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
| ilterChain.java:206)
| at org.jboss.bpm.console.server.util.GWTJsonFilter.doFilter(GWTJsonFilte
| r.java:59)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
| icationFilterChain.java:235)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
| ilterChain.java:206)
| at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFi
| lter.java:96)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
| icationFilterChain.java:235)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
| ilterChain.java:206)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
| alve.java:235)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
| alve.java:191)
| at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(Securit
| yAssociationValve.java:190)
| at org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authentica
| torBase.java:433)
| at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValv
| e.java:92)
| at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.proce
| ss(SecurityContextEstablishmentValve.java:126)
| at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invok
| e(SecurityContextEstablishmentValve.java:70)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
| ava:127)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j
| ava:102)
| at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedC
| onnectionValve.java:158)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
| ve.java:109)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav
| a:330)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java
| :828)
| at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.proce
| ss(Http11Protocol.java:601)
| at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:44
| 7)
| at java.lang.Thread.run(Thread.java:619)
| Caused by: java.lang.RuntimeException: Unexpected invocation exception: null
| at org.jboss.bpm.console.server.util.InvocationProxy.invoke(InvocationPr
| oxy.java:80)
| at $Proxy143.provideForm(Unknown Source)
| at org.jboss.bpm.console.server.FormProcessingFacade.provideForm(FormPro
| cessingFacade.java:181)
| at org.jboss.bpm.console.server.FormProcessingFacade.renderTaskUI(FormPr
| ocessingFacade.java:120)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
| java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
| sorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.
| java:117)
| at org.jboss.resteasy.core.ResourceMethod.invokeOnTarget(ResourceMethod.
| java:260)
| at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:232
| )
| at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:166
| )
| at org.jboss.resteasy.core.DispatcherUtilities.getJaxrsResponse(Dispatch
| erUtilities.java:142)
| at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispa
| tcher.java:356)
| ... 28 more
| Caused by: java.lang.reflect.InvocationTargetException
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
| java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
| sorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at org.jboss.bpm.console.server.util.InvocationProxy.invoke(InvocationPr
| oxy.java:64)
| ... 41 more
| Caused by: java.lang.NullPointerException
| at org.jbpm.integration.console.forms.TaskFormDispatcher.provideForm(Tas
| kFormDispatcher.java:149)
| at org.jbpm.integration.console.forms.FormDispatcherComposite.provideFor
| m(FormDispatcherComposite.java:65)
| ... 46 more
| 13:00:08,559 ERROR [[Resteasy]] Servlet.service() for servlet Resteasy threw exc
| eption
| org.jboss.resteasy.spi.UnhandledException: java.lang.RuntimeException: Unexpecte
| d invocation exception: null
| at org.jboss.resteasy.core.SynchronousDispatcher.handleApplicationExcept
| ion(SynchronousDispatcher.java:319)
| at org.jboss.resteasy.core.SynchronousDispatcher.handleException(Synchro
| nousDispatcher.java:230)
| at org.jboss.resteasy.core.SynchronousDispatcher.handleInvokerException(
| SynchronousDispatcher.java:206)
| at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispa
| tcher.java:360)
| at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispa
| tcher.java:173)
| at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.servi
| ce(HttpServletDispatcher.java:93)
| at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.servi
| ce(HttpServletDispatcher.java:68)
| at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
| icationFilterChain.java:290)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
| ilterChain.java:206)
| at org.jboss.bpm.console.server.util.GWTJsonFilter.doFilter(GWTJsonFilte
| r.java:59)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
| icationFilterChain.java:235)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
| ilterChain.java:206)
| at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFi
| lter.java:96)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
| icationFilterChain.java:235)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
| ilterChain.java:206)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
| alve.java:235)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
| alve.java:191)
| at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(Securit
| yAssociationValve.java:190)
| at org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authentica
| torBase.java:433)
| at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValv
| e.java:92)
| at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.proce
| ss(SecurityContextEstablishmentValve.java:126)
| at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invok
| e(SecurityContextEstablishmentValve.java:70)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
| ava:127)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j
| ava:102)
| at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedC
| onnectionValve.java:158)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
| ve.java:109)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav
| a:330)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java
| :828)
| at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.proce
| ss(Http11Protocol.java:601)
| at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:44
| 7)
| at java.lang.Thread.run(Thread.java:619)
| Caused by: java.lang.RuntimeException: Unexpected invocation exception: null
| at org.jboss.bpm.console.server.util.InvocationProxy.invoke(InvocationPr
| oxy.java:80)
| at $Proxy143.provideForm(Unknown Source)
| at org.jboss.bpm.console.server.FormProcessingFacade.provideForm(FormPro
| cessingFacade.java:181)
| at org.jboss.bpm.console.server.FormProcessingFacade.renderTaskUI(FormPr
| ocessingFacade.java:120)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
| java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
| sorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.
| java:117)
| at org.jboss.resteasy.core.ResourceMethod.invokeOnTarget(ResourceMethod.
| java:260)
| at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:232
| )
| at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:166
| )
| at org.jboss.resteasy.core.DispatcherUtilities.getJaxrsResponse(Dispatch
| erUtilities.java:142)
| at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispa
| tcher.java:356)
| ... 28 more
| Caused by: java.lang.reflect.InvocationTargetException
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
| java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
| sorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at org.jboss.bpm.console.server.util.InvocationProxy.invoke(InvocationPr
| oxy.java:64)
| ... 41 more
| Caused by: java.lang.NullPointerException
| at org.jbpm.integration.console.forms.TaskFormDispatcher.provideForm(Tas
| kFormDispatcher.java:149)
| at org.jbpm.integration.console.forms.FormDispatcherComposite.provideFor
| m(FormDispatcherComposite.java:65)
| ... 46 more
|
Here are the two forms. The first one is taken from one of the examples.
| <html>
| <body>
|
| <h2>How many days would you like to go on vacation?</h2>
| <form action="${form.action}" method="POST" enctype="multipart/form-data">
| <select name="number_of_days">
| <option value="3">3 days</option>
| <option value="5">5 days</option>
| <option value="10">10 days</option>
| </select><br>
|
| <#list outcome.values as transition>
| <input type="submit" name="outcome" value="${transition}">
| </#list>
|
| </form>
| </body>
| </html>
|
| <html>
| <body>
|
| <h2>[Human Resources]Do you approve the vacation request?</h2>
| <form action="${form.action}" method="POST" enctype="multipart/form-data">
| <select name="acceptance_hr">
| <option value="yes">yes</option>
| <option value="no">no</option>
| </select><br>
|
| <#list outcome.values as transition>
| <input type="submit" name="outcome" value="${transition}">
| </#list>
|
| </form>
| </body>
| </html>
|
I am kind of confused since I do not really see a difference which would explain why the first one works properly and the second one does not.
Any hints?
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4249896#4249896
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4249896
More information about the jboss-user
mailing list