AnsweredAssumed Answered

DB updated not in time during process execution

Question asked by kayj on Mar 23, 2015
Latest reply on Jul 28, 2015 by jbarrez

I need to get notified (without adding ExecutionListeners to the BPMN model) about events. I'm using ActivitiEventListener to get notified.

mProcessEngine.getRuntimeService().addEventListener( new ActivitiEventListener() {
  public void onEvent(ActivitiEvent event) {

Unfortunately it doesn't work as expected. It seems like the Activiti DB is not updated until a blocking entity is reached (e.g. waiting for a signaling). As a result of this behaviour I can't access variables from the DB which have already been written by a ScriptTask in the BPMN model, but are not yet written to the DB. Is this intended behaviour? Is it possible to force an update? Or do you have  different options for the requirement of getting nofied without adding listeners to the BPMN model?

Thank in advance,