cancel
Showing results for 
Search instead for 
Did you mean: 

Why RuntimeService.deleteProcessInstance() do one by one db call for variables select and deletes?

swamy2156
Champ on-the-rise
Champ on-the-rise
Hi,

I recently upgraded Activiti to 5.19 and enabled bulkInsertEnabled in processEngineConfiguration.
I really like this feature and thanks for providing which really improved performance of my app.
I am using RuntimeService.deleteProcessInstance() to delete a processInstance. I got few queries and putting here to clear.
As part of delete process instance
1) collecting ACT_RU_VARIABLE s one by one using select query by ID_ for process instance. Why activiti is not collecting all at once(using processInstanceId or executionId) at this step?
2) its deleting ACT_RU_VARIABLE one by one instead of bulk delete(using processInstanceId or executionId). Is there a way to delete all in one shot to minimise db calls?
1 REPLY 1

trademak
Star Contributor
Star Contributor
I think that's indeed an area where we can improve the number of SQL statements executed.
Can you create a JIRA issue?

Best regards,