JBoss Community

Re: How to signal process event from a custom WorkItemHandler?

created by Thomas Setiabudi in jBPM - View the full discussion

Hi Maciej,

 

Thank you for your answer.

 

If I were to make a custom WorkItemHandler and need to inject ksession to it, that means instead of registering my workitemhandler in

jbpm-installer\jboss-as-7.1.1.Final\standalone\deployments\jbpm-gwt-console-server.war\WEB-INF\classes\META-INF\CustomWorkItemHandlers.conf

 

I would need to inject it in

\jbpm-installer\jboss-as-7.1.1.Final\standalone\deployments\jbpm-gwt-console-server.war\WEB-INF\classes\default.session.template

 

and change this part

 

 workItemHandlers = [Human Task : "new app.chameleon.bpm.workitemhandler.humantask.hornetq.ChameleonHTHornetQWIH(\"jbpmConsoleHTHandler\, taskClient, ksession, org.jbpm.task.utils.OnErrorAction.LOG),
                        Service Task : new org.jbpm.process.workitem.bpmn2.ServiceTaskHandler(ksession)],
 

 

to

 

 

 workItemHandlers = [Human Task : "new app.chameleon.bpm.workitemhandler.humantask.hornetq.ChameleonHTHornetQWIH(\"jbpmConsoleHTHandler\, taskClient, ksession, org.jbpm.task.utils.OnErrorAction.LOG),
                        Service Task : new org.jbpm.process.workitem.bpmn2.ServiceTaskHandler(ksession),
                          MyCustomTask : new my.custom.workitem.handler.myWorkItemHandler(kession)],

 

and then register a .wid for MyCustomTask.

 

will that works?

 

 

Regards,

Thomas Setiabudi

 



Reply to this message by going to Community

Start a new discussion in jBPM at Community