[jboss-user] [jBPM] - Get subprocess id from outside the process

Michael Wohlfart do-not-reply at jboss.com
Mon Aug 2 14:45:58 EDT 2010


Michael Wohlfart [http://community.jboss.org/people/mwohlf] replied to the discussion

"Get subprocess id from outside the process"

To view the discussion, visit: http://community.jboss.org/message/555491#555491

--------------------------------------------------------------
I tried to reproduce this issue so I added a testcase to
org.jbpm.examples.subprocess.outcomeactivity.SubProcessOutcomeActivityTest


but the following testcase passed for me:
public void testSubProcessIdQuery() {
        ProcessInstance processInstance = executionService.startProcessInstanceByKey("SubProcessDocument");
        final Execution execution = processInstance.findActiveExecutionIn("review");
        assertNotNull(execution);
        assertNotNull(processEngine);
        String pid = ((ExecutionImpl) execution).getSubProcessInstance().getId();
        assertNotNull(pid);
        List<Task> taskList = taskService.findPersonalTasks("johndoe");
        Task task = taskList.get(0);
        taskService.completeTask(task.getId(), "reject");
}


so maybe if you post your testcase someone is able to shed some light on this

--------------------------------------------------------------

Reply to this message by going to Community
[http://community.jboss.org/message/555491#555491]

Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20100802/a836042a/attachment.html 


More information about the jboss-user mailing list