Camunda unexpectedly finishes process in the middle

Hello, guys! Hope you are well!

I just faced with very unpleasant situation:

  1. I have a process definition with a few external tasks, gateways, timers and a few user tasks;
  2. Initially it works fine, but I noticed that from time to time Camunda finish process in the middle;

For example process may stops after:

  1. user task 1;
  2. user task2;

And I completely do not understand what is going on. Maybe some of you faced with such a problem or has any ideas?

Can you upload the process model?
When you say “stops” can you describe that in more detail?

Hello, Niall!

This is the real workflow I used. I replaced meaningful names with some stubs.
for_camunda_forum.bpmn (25.8 KB)

When I say “stops”. I mean that process finishes unexpectedly in the middle of flow. F.e. after the first user task.

Is there any indication form the logs about what might be going wrong?
What does the history of the process does it say the process was cancelled?

I completely forgot to say that “mock-task-topic” handler wait for 1.5 minutes and then complete an external task.

There was no errors in Camunda logs.
And I am investigating history right now (It’s quite tough).

Niall, looks like everything fine with Camunda except timers.

I checked history and process instance completed correctly.

But there are 2 external tasks in my process definition with bounded timer events. In both cases I put PT1M (1 minute) duration on it. And external task waits for 1.5 minutes before complete. And it work fine sometimes. But looks like sometimes timers does not work.

I have read that 1 minute and less timers may cause some problems. Is it true?

If not, then issue with mu external task handler.

Can you explain what exactly doesn’t work - do they not execute at all or do the execute too late?

I have the following situation:

According to image I always have to go to UserTask_1.

But from time to time process instance

  1. goes to UserTask_1. In this case in act_hi_actinst table I see BoundaryTimerEvent;

  2. sometimes it goes to another branch. In this case in act_hi_actinst no BoundaryTimerEvent exists.

Ok i understand the problem and i know what you need you do.
The issue is with the frequency at which your job executor is getting jobs.
Each time a timer is created in the database it has a date which it will be executed - the job executor periodically checks for jobs and if it find them it executed them if not it waits for a set time before checking again. So it seems like you need to have the job executor poll for jobs more often.

You should check out this great blog post written by @thorben for more information.

1 Like

Got it. Thank you for the advice, Niall. I will check it.