[jboss-user] [JBoss jBPM] - jbpm 3.2.2

manjula_athani do-not-reply at jboss.com
Mon Feb 18 05:33:46 EST 2008

Hi all,

I'm using jboss jbpm 3.2.2. using graphical tool created my application in which I want embed an action on a particular event/ transition. when that action class is invoked I get this exception : 

Error signalling token: An exception of type "org.jbpm.graph.def.DelegationException" was thrown. 


<process-definition  xmlns=""  name="Hello2">

	<start-state name="start">

	<task-node name="process">

	<task-node name="show sum">

	<end-state name="end"></end-state>

MyAction is available in the same package as that of processDefinition.xml

import org.jbpm.context.exe.ContextInstance;
import org.jbpm.graph.def.ActionHandler;
import org.jbpm.graph.def.ProcessDefinition;
import org.jbpm.graph.exe.ExecutionContext;
import org.jbpm.graph.exe.ProcessInstance;

public class MyAction implements ActionHandler {
	 private static final long serialVersionUID = 1L;

	 public void execute(ExecutionContext executionContext) throws Exception {
	  // TODO Auto-generated method stub
	  ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("processdefinition.xml");
	  ProcessInstance processInstance =  new ProcessInstance(processDefinition);
	  ContextInstance contextInstance =   processInstance.getContextInstance();
	  String getnum1 = (String)contextInstance.getVariable("num1");
	  String getnum2 = (String) contextInstance.getVariable("num2");
	  String  sum = getnum1 + getnum2;



kindly help.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4130045#4130045

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4130045

More information about the jboss-user mailing list