cancel
Showing results for 
Search instead for 
Did you mean: 

Boundary Timer Event Firing After Subprocess Finished

rallen1
Confirmed Champ
Confirmed Champ
Hello,

I'm having some issues with the boundary timer event firing after the flow has progressed out of the subprocess. I'd really appreciate any help. All files attached at bottom work with the activiti unit test, just rename without .txt (and forum added underscores).

The issue becomes more apparent when scripttask4 is set to activiti:async=true. The process seems to get stuck indefinitely.

Note: I need to use the jobExecutor rather than the asyncExecutor because the asyncExecutor was having ActivitiOptimisticLockingException's on some BPMNs under heavy load (https://forums.activiti.org/content/null-issues-when-under-heavy-throughput).

Thank you for any help.
2 REPLIES 2

martin_grofcik
Confirmed Champ
Confirmed Champ
Hi rallen,

I have tested your case. The test test has passed with {{async='false'}}. With the async flag true on the scripttask4 the test is failing.
I did not investigate it a lot, but my guess is that

      <timerEventDefinition>
        <timeDate>2007-03-01T13:00:00Z</timeDate>
      </timerEventDefinition>
Timer is fired before it is removed by async call.
The problem could be that timer is not removed when execution leaves subprocess. There are many workarounds increase timer….

Regards
Martin

rallen1
Confirmed Champ
Confirmed Champ
Hey Martin,

Thank you for taking the time to look at it.

There are cases during the BPMN where the timer may be in the past (most cases it will not be). It was set in the past for the purpose of the test. I was under the impression that once a subprocess has concluded any timers whether active or not, would be destroyed. Also, in my BPMN I require the task after the subprocess to be activiti:async=true, which halts the BPMN as observed. My actual BPMN is crashing because of this. That seems like it might be a bug if an async=true task can't be resumed after a late boundary timer.

Again, thank you for your help. I really appreciate it.