02-27-2014 03:32 AM
public void detectProcStatusFromActivity() {
if(this.status == null) {
if (this.processInstanceId == null) {
LOG.debug("Could not detect processState without processInstanceId");
} else {
try {
List<Execution> executions = getActivitiRuntimeService().createExecutionQuery()
.processInstanceId(this.processInstanceId).list();
if (executions.isEmpty()) {
this.status = ProcStatus.CLOSED;
}
} catch (ActivitiException e) {
LOG.debug(
"Exception while trying to find Activiti process instance for instanceId {}, " +
"assuming new process state: CLOSED.", processInstanceId, e);
this.status = ProcStatus.CLOSED;
}
}
}
}
03-01-2014 08:57 AM
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.