07-19-2019 06:21 AM
Hi,
I am using Alfresco One Enterprise with activiti.
I created and published a couple of activity apps.
The apps includes some processes with javascript actions. When I started an instance of the processes I figured out that there are some errors in the scripts so I corrected the processes published the apps and started new instance and they are working fine now.
The issue is that the instances which had problems in the scripts created some exceptions and could not complete. when I am trying to cancel or delete them form the activiti web interface or from activiti admin I am getting exceptions.
How I can delete these instances?
not able to deleting them will now prevent the deletion of the app they were part of
I will attache the exceptions
Thanks
12-17-2020 03:08 PM
Hi @emadhusam ,
Have you found a solution to this problem? I have a similar situation and I'm looking for a solution. Thanks!
12-18-2020 02:58 AM
Hello,
You have to delete the processes from the database first.
whereas you have to replace X with the instance ID of the problematic instance:
delete from ACT_EVT_LOG where proc_inst_id_ = 'X';
delete from ACT_RU_JOB where process_instance_id_ in (select id_ from ACT_RU_EXECUTION where proc_inst_id_ = 'X');
delete from ACT_RU_VARIABLE where proc_inst_id_ in (select id_ from ACT_RU_EXECUTION where proc_inst_id_ = 'X');
delete from ACT_GE_BYTEARRAY where id_ in (select id_ from ACT_RU_VARIABLE where proc_inst_id_ = 'X');
delete from ACT_RU_EVENT_SUBSCR where proc_inst_id_ = 'X';
delete from ACT_RU_IDENTITYLINK where proc_inst_id_ = 'X';
delete from ACT_RU_TASK where proc_inst_id_ = 'X';
// Take the parent_id into account for subprocesses
delete from ACT_RU_EXECUTION where parent_id_ = 'X';
delete from ACT_RU_EXECUTION where proc_inst_id_ = 'X' or id_ = 'X';
delete from ACT_HI_ACTINST where proc_inst_id_ = 'X' or execution_id_ = 'X';
delete from ACT_HI_PROCINST where proc_inst_id_ = 'X' or id_ = 'X';
delete from ACT_HI_TASKINST where proc_inst_id_ = 'X' or id_ = 'X';
delete from ACT_HI_VARINST where proc_inst_id_ = 'X' or execution_id_ = 'X';
delete from ACT_HI_DETAIL where proc_inst_id_ = 'X' or execution_id_ = 'X';
delete from ACT_HI_IDENTITYLINK where proc_inst_id_ ='X';
12-18-2020 03:13 AM
Thank you @emadhusam !
12-18-2020 03:15 AM
You are welcome.
Explore our Alfresco products with the links below. Use labels to filter content by product module.