User task completion + async processing

Hi,

I have a process definition that I start programmatically in an async way.
Basically the process is like this:

  1. ServiceTask
  2. UserTask
  3. ServiceTask

The first serviceTask is executed asynchronously. I see the threadPoolExecutor thread in the log and I see the entry in the ACT_RU_JOB table.

08:35:03.896 [http-nio-8181-exec-3] DEBUG o.f.j.s.i.p.e.J.insertJob - ==>  Preparing: insert into ACT_RU_JOB
08:35:04.097 [http-nio-8181-exec-3] DEBUG o.f.j.s.i.p.e.J.insertJob - <==    Updates: 1
08:35:04.905 [threadPoolTaskExecutor-1] DEBUG o.f.j.s.i.p.e.J.selectJob - ==>  Preparing: select * from ACT_RU_JOB where ID_ = ?
08:35:04.906 [threadPoolTaskExecutor-1] DEBUG o.f.j.s.i.p.e.J.selectJob - ==> Parameters: 25c78b0d-2b1e-11ec-8eef-34f39ad36c83(String)
08:35:05.101 [threadPoolTaskExecutor-1] DEBUG o.f.j.s.i.p.e.J.selectJob - <==      Total: 1

Then the flow arrives in a wait state in the user task.
I programmatically complete the task:

taskService.complete(userTask.getId()

What I would like and what I expect is that the second service task is also executed asynchronously but I don’t see any jobs in the table nor threadPoolExecutor thread in the log. (It is executed in the controller thread (http-nio-8181-exec-) from which I issued the complete method).

I tried to add async = true for the user task and service tasks but it didnt’ help.

I use flowable 6.6.0 + spring boot 2.3

Any ideas?

Thank you.

Any thoughts would be appreciated.