Activiti Optimistic Lock Exception with async=true - Activiti 6

cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
artur17
Member II

Activiti Optimistic Lock Exception with async=true - Activiti 6

I have a problem with Activiti Optimistic Lock Exception when using async = true.
My goal is for Activiti

- to return Activiti result immediately after 'ServiceTask0'

- executing 'ServiceTask1(setting async=true) i ServiceTask2' independently - without repetition. These are tasks that last a long time.

Currently, after completing ServiceTask0, Activity execute ServiceTask1 and ServiceTask2 asynchorically, and after the all process I get Activiti Optimistic Lock Exception. (when 'activiti-async-job-executor-thread-1' doing 'update ACT_RU_EXECUTION' ).

Then the process is repeated for ServiceTask1 and ServiceTask2 and the second time it ends correctly.

However, I do not want ServiceTask1 and ServiceTAske2 to be repeated.

Activiti ver 6.

Simple flow:

Start -> ServiceTask0 -> ServiceTask1 with async=true -> ServiceTask2 -> End