cancel
Showing results for 
Search instead for 
Did you mean: 

Boundary timer is not fired

slaimankoeik
Champ in-the-making
Champ in-the-making
Hi everyone
I'm designing a workflow in BPMN 2.0,I've uploaded all the necessary files, in summary my workflow starts with a standard start event followed by a java service task which is bounded to a java class named test7, one more thing for java service task is having a boundary timer set for 1 second if fired the flow will submit to a script task which outputs a small text, if not fired flow will submit to another script task.

the problem is the boundary timer is not fired , even with job executor and AsyncExecutor are activated.
if anyone has an idea for this situation ?
6 REPLIES 6

martin_grofcik
Confirmed Champ
Confirmed Champ
Duplicate
  JobTestHelper.waitForJobExecutorToProcessAllJobs(this.activitiRule, 10000, 500);

slaimankoeik
Champ in-the-making
Champ in-the-making
thanks martin for your response, but i added JobTestHelper.waitForJobExecutorToProcessAllJobs(this.activitiRule, 10000, 500); to my main java class but the same result the timer boundary event didn't fire.

i've uploaded the new main java class.

slaimankoeik
Champ in-the-making
Champ in-the-making
martin
one more thing i noticed during debugging the project i will write three statements which interrupted me :

<code> 4105 [main] INFO org.activiti.engine.impl.jobexecutor.JobExecutor - Starting up the JobExecutor[org.activiti.engine.impl.jobexecutor.DefaultJobExecutor].
4106 [Thread-6] INFO org.activiti.engine.impl.jobexecutor.AcquireJobsRunnableImpl - JobExecutor[org.activiti.engine.impl.jobexecutor.DefaultJobExecutor] starting to acquire jobs
4636 [main] INFO org.activiti.engine.impl.jobexecutor.JobExecutor - Shutting down the JobExecutor[org.activiti.engine.impl.jobexecutor.DefaultJobExecutor].
4636 [Thread-6] INFO org.activiti.engine.impl.jobexecutor.AcquireJobsRunnableImpl - JobExecutor[org.activiti.engine.impl.jobexecutor.DefaultJobExecutor] stopped job acquisition <code>

the job executor is shutting down why is that happening ?

jbarrez
Star Contributor
Star Contributor
Boundary timers don't work on automatic steps like script and service task.

slaimankoeik
Champ in-the-making
Champ in-the-making
thanks jbarrez for your response,

[[foo]] Boundary timers don't work on automatic steps like script and service task [[foo]]
i will agree with you on this, then boundary timers work on user task and receive task.
In this case i want to ask something because till now i didn't understand it well, does timers fire automatic (i mean just drawing the workflow and setting the properties of timer) or i should write a piece of code in the main class to make it fire manually like managementService.executeJob(timer.getId());
i made this project to understand the mechnism of boundary timers but can anybody explain for me why the timer is not fired and when i used the executeJob method to run the timer it fired presently ?
can anybody explain the working mechanism for boundary timers ?
Regards.

jbarrez
Star Contributor
Star Contributor
" does timers fire automatic"

If you enable and activate the job executor (or better, use the new Async Executor), then yes.
My guess is that you haven't enabled the executor, if they don't work.

The executeJob method is only there for manual execution (testing or jobs that failed).