cancel
Showing results for 
Search instead for 
Did you mean: 

Timer Start Event fired only once?

chris_joelly
Champ in-the-making
Champ in-the-making
i want to start a process e.g. every 30 seconds and added the following to the process definition:

      … from a modeller process definition …
      <startEvent id="Start_every_30sec_3" name="Start every 30sec">
         <timerEventDefinition id="….">
            <timeCycle id="…." xsi:type="tFormalExpression">0/30 * * * * ?</timeCycle>
         </timerEventDefinition>
      </startEvent>
From the user guide i read the following:
A timer start event is used to create process instance at given time. It can be used both for processes which should start only once and for processes that should start in specific time intervals.
I set jobExecutorActivate to true and when i start the process it is only executed once. How can i set the
Timer Start event so that the process is started periodically?
3 REPLIES 3

frederikherema1
Star Contributor
Star Contributor
That's strange. We have a unit-test for this: org.activiti.engine.test.bpmn.event.timer.BoundaryTimerNonInterruptingEventTest.testTimerWithCycle. It's using:

<timerEventDefinition>
                <timeCycle>R/PT1H</timeCycle>
            </timerEventDefinition>

but It also works with:

<timerEventDefinition>
                <timeCycle>0 1 * * * ?</timeCycle>
            </timerEventDefinition>

trademak
Star Contributor
Star Contributor
Hi,

I gave it a try myself and with the Activiti Explorer it works fine for me.
Every 30 seconds a new process instance is created.
How did you do your test?

Best regards,

chris_joelly
Champ in-the-making
Champ in-the-making
sorry. i think i had some confusion. i started the process and it was executed immediately.
and afterwards i missed the executions in the log file. Smiley Sad