[jboss-user] [JBoss jBPM] - createTaskInstance results in null token

holly77 do-not-reply at jboss.com
Mon Jul 30 08:16:12 EDT 2007


I got an ActionHandler that is creating a TaskInstance dynamically.
I tried this in several ways. E.g.:


  | 	public void execute(ExecutionContext executionContext) throws Exception {
  | 		Token token = executionContext.getToken();
  | 		TaskMgmtInstance tmi = executionContext.getTaskMgmtInstance();
  | 		Task task = tmi.getTaskMgmtDefinition().getTask("someTask");
  | 		executionContext.setTask(task);
  | 		TaskInstance ti = tmi.createTaskInstance(task, executionContext);
  | 		executionContext.setTaskInstance(ti);
  | 		ti.start();
  | 	}
  | 

My problem is, that no matter which why I tried to create a TaskInstance the associated Token, TaskMgmtInstance, Create and Start Date are NULL.

Anybody got a clue, what I'm doing wrong?

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

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



More information about the jboss-user mailing list