Why are my Activiti processes being deleted mid process?

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

Why are my Activiti processes being deleted mid process?

I'm running Activiti 5.19 and find no records of any DELETE method in the access logs yet some of my processes are flagged as deleteReason: "ACTIVITI_DELETED". It appears from the logs that the process was still midway through executing and still had a few tasks left to do yet 3 minutes after the last task ended the process is deleted and no more tasks thus execute.

Is there any reason that this could happen and anywhere to look for what caused this?

The only thing I've found is this error:

Oct 19, 2017 4:52:05 PM com.vaadin.Application terminalError

SEVERE: Terminal error:

com.vaadin.event.ListenerMethod$MethodException: Invocation of method valueChange in org.activiti.explorer.ui.process.ProcessInstancePage$1 failed.

        at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:530)

        at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:164)

        at com.vaadin.ui.AbstractComponent.fireEvent(AbstractComponent.java:1219)

        at com.vaadin.ui.AbstractField.fireValueChange(AbstractField.java:897)

        at com.vaadin.ui.AbstractField.setValue(AbstractField.java:529)

        at com.vaadin.ui.AbstractSelect.setValue(AbstractSelect.java:676)

        at com.vaadin.ui.AbstractSelect.changeVariables(AbstractSelect.java:485)

        at com.vaadin.ui.Table.changeVariables(Table.java:2670)

        at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.changeVariables(AbstractCommunicationManager.java:1460)

        at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.handleVariableBurst(AbstractCommunicationManager.java:1404)

        at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.handleVariables(AbstractCommunicationManager.java:1329)

        at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.doHandleUidlRequest(AbstractCommunicationManager.java:761)

        at com.vaadin.terminal.gwt.server.CommunicationManager.handleUidlRequest(CommunicationManager.java:325)

        at com.vaadin.terminal.gwt.server.AbstractApplicationServlet.service(AbstractApplicationServlet.java:501)

        at javax.servlet.http.HttpServlet.service(HttpServlet.java:731)

        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)

        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)

        at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)

        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)

        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)

        at org.activiti.explorer.filter.ExplorerFilter.doFilter(ExplorerFilter.java:53)

        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)

        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)

        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:218)

        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)

        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:505)

        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:169)

        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)

        at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:958)

        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)

        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:452)

        at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1087)

        at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:637)

        at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316)

        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)

        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)

        at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)

        at java.lang.Thread.run(Thread.java:745)

Caused by: java.lang.NullPointerException

        at org.activiti.explorer.ui.management.processinstance.ProcessInstanceDetailPanel.<init>(ProcessInstanceDetailPanel.java:110)

        at org.activiti.explorer.ui.process.ProcessInstancePage$1.valueChange(ProcessInstancePage.java:60)

        at sun.reflect.GeneratedMethodAccessor760.invoke(Unknown Source)

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

        at java.lang.reflect.Method.invoke(Method.java:606)

        at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:510)

        ... 37 more

I'm also having an issue in a different workflow regarding ActivitiOptimisticLockingExceptions which i've been unable to track down why/how the process is being updated by another transaction...

2 Replies
Senior Member II

Re: Why are my Activiti processes being deleted mid process?

Sounds strange. The reason 'ACTIVITY_DELETED' is usually set when you cancel a running process using the delete API. Can you check your process/environment and make sure that no-one else is using this API against your processes instances!

DELETE runtime/process-instances/{processInstanceId} or the equivalent Java API
Member II

Re: Why are my Activiti processes being deleted mid process?

Thanks for responding, I thought the same but couldn't find any REST calls. We aren't using the Java API so unless Activiti is doing it itself i'm having difficulty tracking down the problem. I know the explorer UI doesn't use the REST interface unfortunately so there's a slim chance someone is clicking "delete" on the process but we've not found anyone with access who would do that and there are sometimes up to 3 processes deleted within the same second.