AnsweredAssumed Answered

Implement a waitstate with a timerevent

Question asked by werners on Jun 15, 2014
Latest reply on Jun 27, 2014 by jbarrez
Hi all,

maybe someone can give me some hint to solve the problem.

This is the subprocess:

startEvent → timerEvent → JavaServiceTask→ Exclusive Gateway  - endEvent

Depending on the result of  the service task, the exclusive gateway has to output-flows ( either to the endEvent or back to the timerEvent)

The timerEvent should cause a waiting time (in example one day) and either then the process will end (continue the parentprocess) or (depending on the result in serviceTask) sleep one day to retry.

I thought that it would be possible to implement this „waitstate“ easily with the following code:

<intermediateCatchEvent id="sid-00072" name="TimerCatchEvent">

But when i execute the process, i get always the error message, and i think that the message is related to my timerEvent…

15 Jun 2014 22:29:01,183 [main] ERROR org.activiti.engine.impl.interceptor.CommandContext:140 - Error while closing command context
org.activiti.engine.ActivitiException: couldn't resolve duedate: 1
   at org.activiti.engine.impl.calendar.DurationBusinessCalendar.resolveDuedate(

Is it possible to implement this waitstate with an timerevent? How can i do this and why is there a need for a duedate?