8 Replies Latest reply on Dec 27, 2006 12:44 PM by dslevine

    AssignmentHandler problem

    Bruno Souza Newbie

      Hi all,

      I was trying to implement an AssignmentHandler to replace the ExpressionAssignmentHandler. In the docs, the section '11.11.3. Removing the identity component', says:


      The ExpressionAssignmentHandler is dependent on the identity component so you will not be able to use it as is. In case you want to reuse the ExpressionAssignmentHandler and bind it to your user data store, you can extend from the ExpressionAssignmentHandler and override the method getExpressionSession.


      Following these instructions, I especified my AssignmentHandler implementation (that extends ExpressionAssignmentHandler) at the 'class' attribute of the assignment tag and found that my AssignmentHandler wasn't instantiated when the 'expression' attribute is especified in the same tag.

      There are any other necessary steps to take, other than extending the ExpressionAssignmentHandler, override its method and specify the new class at the 'class' attribute in the assignment tag ?

      Any help appreciated!

      Thanks,
      Bruno

        • 1. Re: AssignmentHandler problem
          Bruno Souza Newbie

          Btw, I'm using jBPM starter's kit 3.1.3

          • 2. Re: AssignmentHandler problem
            Chris OBrien Novice

            I am using a custom AssignmentHandler, and we have the identity component removed.

            We just extend from "AssignmentHandler" and never touch that ExpressionAssignmentHandler.

            Then just specify your new class as the appropriate handler, and you should be set

            • 3. Re: AssignmentHandler problem
              dslevine Newbie

              Could you please be a little more in depth as to how you remove the identity component and implement your own?

              If I create the class MyAssignmentHandler in my project, how do I tell jBPM to use that specific assignment handler? Are there any other steps you went through?

              Thanks!

              (I also cannot extend ExpressionAssignmentHandler, as I already have a hibernate object User and get a conflict on trying to import the identity hibernate objects.)

              • 4. Re: AssignmentHandler problem
                dslevine Newbie

                To be a little more clear, I have tried to use

                <task name="MyTask">
                 <assignment class="com.myapp.MyAssignmentHandler" expression="user(me)"/>
                 ...
                


                and I have tried to use swimlanes and do

                 <swimlane name="SwimlaneMe">
                 <assignment class="com.myapp.MyAssignmentHandler" expression="user(me)"/>
                 </swimlane>
                
                 ...
                
                 <task name="MyTask" swimlane="SwimlaneMe">
                
                 ...
                
                


                But both times the app still calls to ExpressionAssignmentHandler to calculate user(me).

                Thanks!

                • 5. Re: AssignmentHandler problem
                  dslevine Newbie

                  Exact process def:

                  <?xml version="1.0" encoding="UTF-8"?>
                  
                  <process-definition name="websale"
                   xmlns="urn:jbpm.org:jpdl-3.1">
                  
                   <!-- SWIMLANES (= process roles) -->
                  
                   <swimlane name="buyer" />
                  
                   <swimlane name="salesman">
                   <assignment class='tv.current.base.workflow.CurrentAssignmentHandler' expression="user(danlevine)" />
                   </swimlane>
                  
                   <swimlane name="accountant">
                   <assignment class='tv.current.base.workflow.CurrentAssignmentHandler' expression="user(sforte)" />
                   </swimlane>
                  
                   <swimlane name="shipper">
                   <assignment class='tv.current.base.workflow.CurrentAssignmentHandler' expression="user(lastmanstanding)" />
                   </swimlane>
                  
                   <!-- NODES -->
                  
                   <start-state name="create new web sale order">
                   <task swimlane="buyer">
                   <controller>
                   <variable name="item"/>
                   <variable name="quantity"/>
                   <variable name="address"/>
                   </controller>
                   </task>
                   <transition to="evaluate web order" />
                   </start-state>
                  
                   <task-node name="evaluate web order">
                   <task swimlane="salesman">
                   <controller>
                   <variable name="item" access="read"/>
                   <variable name="quantity" access="read"/>
                   <variable name="address" access="read"/>
                   <variable name="comment"/>
                   </controller>
                   </task>
                   <transition name="ok" to="salefork" />
                   <transition name="more info needed" to="fix web order data" />
                   </task-node>
                  
                   <task-node name="fix web order data">
                   <task swimlane="buyer">
                   <controller>
                   <variable name="comment" access="read"/>
                   <variable name="item" />
                   <variable name="quantity" />
                   <variable name="address" />
                   </controller>
                   </task>
                   <transition to="evaluate web order" />
                   </task-node>
                  
                   <fork name="salefork">
                   <transition name="payment" to="wait for money" />
                   <transition name="shipping" to="ship item" />
                   </fork>
                  
                   <task-node name="wait for money">
                   <task swimlane="accountant">
                   <controller>
                   <variable name="item" access="read" />
                   <variable name="quantity" access="read" />
                   <variable name="address" access="read" />
                   <variable name="money received" />
                   </controller>
                   </task>
                   <transition to="update books" />
                   </task-node>
                  
                   <node name="update books">
                   <action class="org.jbpm.websale.UpdateBooks">
                   <msg>accountancy application is now informed of the payment</msg>
                   </action>
                   <transition to="salejoin" />
                   </node>
                  
                   <node name="ship item">
                   <action class="org.jbpm.websale.ShipItem">
                   <swimlaneName>shipper</swimlaneName>
                   <msg>${shipper} now ships ${item} to ${address}</msg>
                   </action>
                   <transition to="salejoin" />
                   </node>
                  
                   <join name="salejoin">
                   <transition to="end" />
                   </join>
                  
                   <end-state name="end" />
                  
                  </process-definition>
                  



                  Exact error, when I try to signal a new ProcessInstance:

                  [2006-12-26 19:36:52,996] ERROR org.jbpm.instantiation.Delegation couldn't load delegation class 'org.jbpm.identity.assignment.ExpressionAssignmentHandler'
                  java.lang.ClassNotFoundException: class 'org.jbpm.identity.assignment.ExpressionAssignmentHandler' could not be found by the process classloader
                   at org.jbpm.instantiation.ProcessClassLoader.findClass(ProcessClassLoader.java:67)
                   at java.lang.ClassLoader.loadClass(Unknown Source)
                   at java.lang.ClassLoader.loadClass(Unknown Source)
                   at org.jbpm.instantiation.Delegation.instantiate(Delegation.java:140)
                   at org.jbpm.instantiation.Delegation$$FastClassByCGLIB$$6bae1598.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.instantiation.Delegation$$EnhancerByCGLIB$$b71b4fb5.instantiate(<generated>)
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignmentDelegation(TaskMgmtInstance.java:215)
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:193)
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.getInitializedSwimlaneInstance(TaskMgmtInstance.java:176)
                   at org.jbpm.taskmgmt.exe.TaskInstance.assign(TaskInstance.java:192)
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.createTaskInstance(TaskMgmtInstance.java:148)
                   at org.jbpm.graph.node.TaskNode.execute(TaskNode.java:167)
                   at org.jbpm.graph.def.Node.enter(Node.java:316)
                   at org.jbpm.graph.def.Node$$FastClassByCGLIB$$d187eeda.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$d3d87ebb.enter(<generated>)
                   at org.jbpm.graph.def.Transition.take(Transition.java:119)
                   at org.jbpm.graph.def.Node.leave(Node.java:383)
                   at org.jbpm.graph.node.StartState.leave(StartState.java:70)
                   at org.jbpm.graph.def.Node$$FastClassByCGLIB$$d187eeda.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$d3d87ebb.leave(<generated>)
                   at org.jbpm.graph.exe.Token.signal(Token.java:174)
                   at org.jbpm.graph.exe.Token.signal(Token.java:123)
                   at org.jbpm.graph.exe.Token$$FastClassByCGLIB$$74df1c6e.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.graph.exe.Token$$EnhancerByCGLIB$$3b6607f7.signal(<generated>)
                   at org.jbpm.graph.exe.ProcessInstance.signal(ProcessInstance.java:217)
                   at org.jbpm.graph.exe.ProcessInstance$$FastClassByCGLIB$$5167cc59.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.graph.exe.ProcessInstance$$EnhancerByCGLIB$$569a3998.signal(<generated>)
                   at tv.current.base.workflow.WorkflowService.signalProcessInstance(WorkflowService.java:75)
                   at tv.current.base.workflow.WorkflowService$$FastClassByCGLIB$$ec0f5a03.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.springframework.aop.framework.Cglib2AopProxy$CglibMethodInvocation.invokeJoinpoint(Cglib2AopProxy.java:714)
                   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
                   at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
                   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
                   at org.springframework.aop.framework.Cglib2AopProxy$DynamicAdvisedInterceptor.intercept(Cglib2AopProxy.java:652)
                   at tv.current.base.workflow.WorkflowService$$EnhancerByCGLIB$$74f7a0aa.signalProcessInstance(<generated>)
                   at tv.current.cms.controllers.workflow.WorkflowController.handleRequestInternal(WorkflowController.java:60)
                   at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
                   at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:45)
                   at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:806)
                   at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:736)
                   at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:396)
                   at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:350)
                   at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
                   at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
                   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
                   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:264)
                   at org.acegisecurity.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:107)
                   at org.acegisecurity.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:72)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.ui.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:110)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.ui.rememberme.RememberMeProcessingFilter.doFilter(RememberMeProcessingFilter.java:135)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.ui.AbstractProcessingFilter.doFilter(AbstractProcessingFilter.java:217)
                   at tv.current.base.security.CurrentAuthenticationProcessingFilter.doFilter(CurrentAuthenticationProcessingFilter.java:49)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:193)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.util.FilterChainProxy.doFilter(FilterChainProxy.java:148)
                   at org.acegisecurity.util.FilterToBeanProxy.doFilter(FilterToBeanProxy.java:98)
                   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                   at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
                   at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
                   at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
                   at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
                   at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
                   at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
                   at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
                   at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
                   at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
                   at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
                   at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
                   at java.lang.Thread.run(Unknown Source)
                  [2006-12-26 19:36:53,012] ERROR org.jbpm.instantiation.Delegation couldn't instantiate delegation class 'org.jbpm.identity.assignment.ExpressionAssignmentHandler'
                  java.lang.NullPointerException
                   at org.jbpm.instantiation.FieldInstantiator.newInstance(FieldInstantiator.java:105)
                   at org.jbpm.instantiation.FieldInstantiator.instantiate(FieldInstantiator.java:48)
                   at org.jbpm.instantiation.Delegation.instantiate(Delegation.java:163)
                   at org.jbpm.instantiation.Delegation$$FastClassByCGLIB$$6bae1598.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.instantiation.Delegation$$EnhancerByCGLIB$$b71b4fb5.instantiate(<generated>)
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignmentDelegation(TaskMgmtInstance.java:215)
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:193)
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.getInitializedSwimlaneInstance(TaskMgmtInstance.java:176)
                   at org.jbpm.taskmgmt.exe.TaskInstance.assign(TaskInstance.java:192)
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.createTaskInstance(TaskMgmtInstance.java:148)
                   at org.jbpm.graph.node.TaskNode.execute(TaskNode.java:167)
                   at org.jbpm.graph.def.Node.enter(Node.java:316)
                   at org.jbpm.graph.def.Node$$FastClassByCGLIB$$d187eeda.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$d3d87ebb.enter(<generated>)
                   at org.jbpm.graph.def.Transition.take(Transition.java:119)
                   at org.jbpm.graph.def.Node.leave(Node.java:383)
                   at org.jbpm.graph.node.StartState.leave(StartState.java:70)
                   at org.jbpm.graph.def.Node$$FastClassByCGLIB$$d187eeda.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$d3d87ebb.leave(<generated>)
                   at org.jbpm.graph.exe.Token.signal(Token.java:174)
                   at org.jbpm.graph.exe.Token.signal(Token.java:123)
                   at org.jbpm.graph.exe.Token$$FastClassByCGLIB$$74df1c6e.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.graph.exe.Token$$EnhancerByCGLIB$$3b6607f7.signal(<generated>)
                   at org.jbpm.graph.exe.ProcessInstance.signal(ProcessInstance.java:217)
                   at org.jbpm.graph.exe.ProcessInstance$$FastClassByCGLIB$$5167cc59.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.graph.exe.ProcessInstance$$EnhancerByCGLIB$$569a3998.signal(<generated>)
                   at tv.current.base.workflow.WorkflowService.signalProcessInstance(WorkflowService.java:75)
                   at tv.current.base.workflow.WorkflowService$$FastClassByCGLIB$$ec0f5a03.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.springframework.aop.framework.Cglib2AopProxy$CglibMethodInvocation.invokeJoinpoint(Cglib2AopProxy.java:714)
                   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
                   at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
                   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
                   at org.springframework.aop.framework.Cglib2AopProxy$DynamicAdvisedInterceptor.intercept(Cglib2AopProxy.java:652)
                   at tv.current.base.workflow.WorkflowService$$EnhancerByCGLIB$$74f7a0aa.signalProcessInstance(<generated>)
                   at tv.current.cms.controllers.workflow.WorkflowController.handleRequestInternal(WorkflowController.java:60)
                   at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
                   at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:45)
                   at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:806)
                   at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:736)
                   at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:396)
                   at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:350)
                   at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
                   at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
                   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
                   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:264)
                   at org.acegisecurity.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:107)
                   at org.acegisecurity.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:72)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.ui.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:110)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.ui.rememberme.RememberMeProcessingFilter.doFilter(RememberMeProcessingFilter.java:135)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.ui.AbstractProcessingFilter.doFilter(AbstractProcessingFilter.java:217)
                   at tv.current.base.security.CurrentAuthenticationProcessingFilter.doFilter(CurrentAuthenticationProcessingFilter.java:49)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:193)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.util.FilterChainProxy.doFilter(FilterChainProxy.java:148)
                   at org.acegisecurity.util.FilterToBeanProxy.doFilter(FilterToBeanProxy.java:98)
                   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                   at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
                   at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
                   at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
                   at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
                   at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
                   at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
                   at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
                   at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
                   at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
                   at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
                   at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
                   at java.lang.Thread.run(Unknown Source)
                  [2006-12-26 19:36:53,012] ERROR org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/cms].[cms] Servlet.service() for servlet cms threw exception
                  org.jbpm.graph.def.DelegationException
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:208)
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.getInitializedSwimlaneInstance(TaskMgmtInstance.java:176)
                   at org.jbpm.taskmgmt.exe.TaskInstance.assign(TaskInstance.java:192)
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.createTaskInstance(TaskMgmtInstance.java:148)
                   at org.jbpm.graph.node.TaskNode.execute(TaskNode.java:167)
                   at org.jbpm.graph.def.Node.enter(Node.java:316)
                   at org.jbpm.graph.def.Node$$FastClassByCGLIB$$d187eeda.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$d3d87ebb.enter(<generated>)
                   at org.jbpm.graph.def.Transition.take(Transition.java:119)
                   at org.jbpm.graph.def.Node.leave(Node.java:383)
                   at org.jbpm.graph.node.StartState.leave(StartState.java:70)
                   at org.jbpm.graph.def.Node$$FastClassByCGLIB$$d187eeda.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$d3d87ebb.leave(<generated>)
                   at org.jbpm.graph.exe.Token.signal(Token.java:174)
                   at org.jbpm.graph.exe.Token.signal(Token.java:123)
                   at org.jbpm.graph.exe.Token$$FastClassByCGLIB$$74df1c6e.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.graph.exe.Token$$EnhancerByCGLIB$$3b6607f7.signal(<generated>)
                   at org.jbpm.graph.exe.ProcessInstance.signal(ProcessInstance.java:217)
                   at org.jbpm.graph.exe.ProcessInstance$$FastClassByCGLIB$$5167cc59.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:161)
                   at org.jbpm.graph.exe.ProcessInstance$$EnhancerByCGLIB$$569a3998.signal(<generated>)
                   at tv.current.base.workflow.WorkflowService.signalProcessInstance(WorkflowService.java:75)
                   at tv.current.base.workflow.WorkflowService$$FastClassByCGLIB$$ec0f5a03.invoke(<generated>)
                   at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
                   at org.springframework.aop.framework.Cglib2AopProxy$CglibMethodInvocation.invokeJoinpoint(Cglib2AopProxy.java:714)
                   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:162)
                   at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:107)
                   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
                   at org.springframework.aop.framework.Cglib2AopProxy$DynamicAdvisedInterceptor.intercept(Cglib2AopProxy.java:652)
                   at tv.current.base.workflow.WorkflowService$$EnhancerByCGLIB$$74f7a0aa.signalProcessInstance(<generated>)
                   at tv.current.cms.controllers.workflow.WorkflowController.handleRequestInternal(WorkflowController.java:60)
                   at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
                   at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:45)
                   at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:806)
                   at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:736)
                   at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:396)
                   at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:350)
                   at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
                   at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
                   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
                   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:264)
                   at org.acegisecurity.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:107)
                   at org.acegisecurity.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:72)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.ui.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:110)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.ui.rememberme.RememberMeProcessingFilter.doFilter(RememberMeProcessingFilter.java:135)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.ui.AbstractProcessingFilter.doFilter(AbstractProcessingFilter.java:217)
                   at tv.current.base.security.CurrentAuthenticationProcessingFilter.doFilter(CurrentAuthenticationProcessingFilter.java:49)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:193)
                   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
                   at org.acegisecurity.util.FilterChainProxy.doFilter(FilterChainProxy.java:148)
                   at org.acegisecurity.util.FilterToBeanProxy.doFilter(FilterToBeanProxy.java:98)
                   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                   at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
                   at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
                   at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
                   at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
                   at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
                   at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
                   at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
                   at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
                   at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
                   at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
                   at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
                   at java.lang.Thread.run(Unknown Source)
                  Caused by: java.lang.NullPointerException
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignmentDelegation(TaskMgmtInstance.java:217)
                   at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:193)
                   ... 76 more
                  
                  



                  This is after I removed the identity jar from the classpath, but even with the identity jar in there is just fails on trying to assign with it's handler.

                  • 6. Re: AssignmentHandler problem
                    dslevine Newbie

                    In case anyone else runs into this problem, I think I've stumbled upon a solution. It seems that:

                    <swimlane name="MySwimlane">
                     <assignment class='tv.current.base.workflow.CurrentAssignmentHandler' expression="user(danlevine)"></assignment>
                     </swimlane>
                    


                    will not recognize the custom handler, but this will:

                     <swimlane name="MySwimlane">
                     <assignment class='tv.current.base.workflow.CurrentAssignmentHandler'><expression>user(danlevine)</expression></assignment>
                     </swimlane>
                    


                    as will this:

                     <swimlane name="MySwimlane">
                     <assignment class='tv.current.base.workflow.CurrentAssignmentHandler' >user(danlevine)</assignment>
                     </swimlane>
                    


                    I would've assumed that the latter is the way to go, except that the ExpressionAssignmentHandler entry in the Delegate table matches the one in the middle, so I'll stick with the middle option.

                    Still struggling mightily with trying to implement a custom identity module. As with the Spring set up, I'll post a sample to the Wiki if/when I get it going.

                    d

                    • 7. Re: AssignmentHandler problem
                      Ronald van Kuijk Master

                      d,

                      If you search the forum, you'll see that there are some parts that depend on the current identity module and that it is not fully pluggable (yet). It should become a service as are the other parts of jBPM. So if you really like to contribute, it might be better to try to make it a full service instead of finding a workaround. That way, you would not have to specify a custom assignmenthandler on each task, but do it on a higher level.

                      Just my ?0.014

                      • 8. Re: AssignmentHandler problem
                        dslevine Newbie

                        FUN FUN FUN!

                        I would be happy to do that, but I don't understand the Identity module interaction with the rest of the system well enough to understand the best design for morphing it into a service. I think extending/overriding the identity module is a good place to start, and once I understand better I'll try to refactor into a clean interface.

                        (For instance, I dont understand your other reply about Hibernate config. I'll reply there... :)

                        d