@Override protected org.jbpm.graph.exe.ProcessInstance work() throws Exception { Long processId = BusinessProcess.instance().getProcessId(); if (processId!=null) { //TODO: do we need to cache this?? //return ManagedJbpmContext.instance().getProcessInstanceForUpdate(processId); //JBSEAM-4629: return ManagedJbpmContext.instance().getProcessInstance(processId); } else { return null; } }
public Asynchronous() { if ( Init.instance().isJbpmInstalled() ) { BusinessProcess businessProcess = BusinessProcess.instance(); processId = businessProcess.getProcessId(); taskId = BusinessProcess.instance().getTaskId(); } }