// work item may have been aborted
if (workItemInfo != null) {
WorkItem workItem = internalGetWorkItem(workItemInfo);
workItem.setResults(results);
ProcessInstance processInstance = kruntime.getProcessInstance(workItem.getProcessInstanceId());
workItem.setState(WorkItem.COMPLETED);
// process instance may have finished already
if (processInstance != null) {
processInstance.signalEvent("workItemCompleted", workItem);
}
context.remove(workItemInfo);
if (workItems != null) {
this.workItems.remove(workItem.getId());
}