Hello !
I’m a french developper, I work for a company which uses Flowable engine, and recently, the team decided to upgrade Flowable version from 6.5.0 to 7.0.0M1.
Now, we have a problem when executing End Event / End Terminate event :
Stack Trace from “complete” action, which is supposed to trigger my Process BPMN to End Event :
Exception occured : org.flowable.common.engine.api.FlowableIllegalStateException: Can only trigger a plan item that is in the ACTIVE state at org.flowable.cmmn.engine.impl.agenda.operation.TriggerPlanItemInstanceOperation.run(TriggerPlanItemInstanceOperation.java:47) at org.flowable.common.engine.impl.AbstractEngineConfiguration.lambda$new$0(AbstractEngineConfiguration.java:195) at org.flowable.cmmn.engine.impl.interceptor.CmmnCommandInvoker.executeOperation(CmmnCommandInvoker.java:86) at org.flowable.cmmn.engine.impl.interceptor.CmmnCommandInvoker.executeOperations(CmmnCommandInvoker.java:73) at org.flowable.cmmn.engine.impl.interceptor.CmmnCommandInvoker.execute(CmmnCommandInvoker.java:59) at org.flowable.common.engine.impl.interceptor.TransactionContextInterceptor.execute(TransactionContextInterceptor.java:53) at org.flowable.common.engine.impl.interceptor.CommandContextInterceptor.execute(CommandContextInterceptor.java:105) at org.flowable.common.engine.impl.interceptor.LogInterceptor.execute(LogInterceptor.java:30) at org.flowable.common.engine.impl.cfg.CommandExecutorImpl.execute(CommandExecutorImpl.java:56) at org.flowable.common.engine.impl.cfg.CommandExecutorImpl.execute(CommandExecutorImpl.java:51) at org.flowable.cmmn.engine.impl.runtime.CmmnRuntimeServiceImpl.triggerPlanItemInstance(CmmnRuntimeServiceImpl.java:130) at org.flowable.cmmn.engine.impl.callback.ChildProcessInstanceStateChangeCallback.stateChanged(ChildProcessInstanceStateChangeCallback.java:36) at org.flowable.engine.impl.util.ProcessInstanceHelper.callCaseInstanceStateChangeCallbacks(ProcessInstanceHelper.java:540) at org.flowable.engine.impl.persistence.entity.ExecutionEntityManagerImpl.deleteExecutionAndRelatedData(ExecutionEntityManagerImpl.java:578) at org.flowable.engine.impl.persistence.entity.ExecutionEntityManagerImpl.deleteExecutionAndRelatedData(ExecutionEntityManagerImpl.java:591) at org.flowable.engine.impl.persistence.entity.ExecutionEntityManagerImpl.deleteProcessInstanceExecutionEntity(ExecutionEntityManagerImpl.java:630) at org.flowable.engine.impl.agenda.EndExecutionOperation.handleProcessInstanceExecution(EndExecutionOperation.java:119) at org.flowable.engine.impl.agenda.EndExecutionOperation.handleRegularExecution(EndExecutionOperation.java:300) at org.flowable.engine.impl.agenda.EndExecutionOperation.run(EndExecutionOperation.java:82) at org.flowable.common.engine.impl.AbstractEngineConfiguration.lambda$new$0(AbstractEngineConfiguration.java:195) at org.flowable.engine.impl.interceptor.CommandInvoker.executeOperation(CommandInvoker.java:130) at org.flowable.engine.impl.interceptor.CommandInvoker.executeOperations(CommandInvoker.java:114) at org.flowable.engine.impl.interceptor.CommandInvoker.execute(CommandInvoker.java:72) at org.flowable.engine.impl.interceptor.BpmnOverrideContextInterceptor.execute(BpmnOverrideContextInterceptor.java:26) at org.flowable.common.engine.impl.interceptor.TransactionContextInterceptor.execute(TransactionContextInterceptor.java:53) at org.flowable.common.engine.impl.interceptor.CommandContextInterceptor.execute(CommandContextInterceptor.java:105) at org.flowable.common.spring.SpringTransactionInterceptor.lambda$execute$0(SpringTransactionInterceptor.java:57) at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:140) at org.flowable.common.spring.SpringTransactionInterceptor.execute(SpringTransactionInterceptor.java:57) at org.flowable.common.engine.impl.interceptor.LogInterceptor.execute(LogInterceptor.java:30) at org.flowable.common.engine.impl.cfg.CommandExecutorImpl.execute(CommandExecutorImpl.java:56) at org.flowable.common.engine.impl.cfg.CommandExecutorImpl.execute(CommandExecutorImpl.java:51) at org.flowable.engine.impl.TaskServiceImpl.complete(TaskServiceImpl.java:223)
… (the rest of the stack trace is our application code)
In our database, the item is in “active” state, but also when we are debugging we have the right “Task” element with the right id.
Maybe the “complete” try to complete an other process in an other plan item ?
If you need more informations to help me solve this issue, you can ask me.