Activiti DB queries causing some max spikes of CPU in production environment
Please take a look at the below findings. In summary, the problem is in the query itself due to the datatypes that are defined in the ACTIVITI V6.0 tables.
The following tests were conducted on ACTIVITI V6.0 DB Existing query took9 minutes 53 secondswith (50 eDTUs)! select * from ACT_RU_VARIABLE where EXECUTION_ID_ = 10000074 and NAME_= 'abccd' and TASK_ID_ is null;
New query took3 millisecondswith (50 eDTUs)! No index was created. select * from ACT_RU_VARIABLE where EXECUTION_ID_ = '10000074' and NAME_= 'abccd' and TASK_ID_ is null;
Since the DB tables and queries are managed by Activiti itself, Can you guys please suggest how should be address this?
We thought of changing the datatype but we are not sure how this is going to impact on functional Activiti workflows, so wanted to have your insights as well on it.