Shared Process Engine is dead when BPMN exception occured

Hello,

I have very strange problem. When BPMN error occurred my process engine dies.
My env:

  1. Apache Tomcat 9.0.19
  2. Camunda - 7.11.0
  3. OS - Linux.
  4. DB - Oracle.

We have multiple spring web application deployed on that apache tomcat.
When I made some incorrect implementation into one of them, entire shared camunda engine is died.
For example I have missed to put some variable on task complete. this variable is used into process as an expression. I got this error :

ENGINE-16006 BPMN Stack Trace:
ParallelGateway_04ylt0i (activity-execute, ProcessInstance[b30daba3-a8c2-11e9-b3b1-1062e513950d], pa=processApplication)
ParallelGateway_04ylt0i
    ^
    |
IntermediateThrowEvent_1ehj97d, name=TECH: პროექტირება

After this exception when I open the camunda web interface, I see this error :

org.camunda.bpm.webapp.impl.IllegalWebAppConfigurationException: No process engine found. camunda Webapp cannot work without a process engine. 
	org.camunda.bpm.webapp.impl.engine.ProcessEnginesFilter.getDefaultEngineName(ProcessEnginesFilter.java:177)
	org.camunda.bpm.webapp.impl.engine.ProcessEnginesFilter.serveIndexPage(ProcessEnginesFilter.java:146)
	org.camunda.bpm.webapp.impl.engine.ProcessEnginesFilter.applyFilter(ProcessEnginesFilter.java:114)
	org.camunda.bpm.webapp.impl.filter.AbstractTemplateFilter.doFilter(AbstractTemplateFilter.java:58)
	org.camunda.bpm.webapp.impl.security.filter.headersec.HttpHeaderSecurityFilter.doFilter(HttpHeaderSecurityFilter.java:83)
	org.camunda.bpm.webapp.impl.security.filter.CsrfPreventionFilter.doFilter(CsrfPreventionFilter.java:165)
	org.camunda.bpm.webapp.impl.security.filter.SecurityFilter.doFilterSecure(SecurityFilter.java:71)
	org.camunda.bpm.webapp.impl.security.filter.SecurityFilter.doFilter(SecurityFilter.java:55)
	org.camunda.bpm.webapp.impl.security.auth.AuthenticationFilter$1.execute(AuthenticationFilter.java:62)
	org.camunda.bpm.webapp.impl.security.auth.AuthenticationFilter$1.execute(AuthenticationFilter.java:60)
	org.camunda.bpm.webapp.impl.security.SecurityActions.runWithAuthentications(SecurityActions.java:44)
	org.camunda.bpm.webapp.impl.security.auth.AuthenticationFilter.doFilter(AuthenticationFilter.java:60)

My application setup :
It is spring boot application It is very useful and good to use for running engine locally (for debugging etc.)
But we build web application for deployment. After war build we put it into tomcat.

Camunda configuration looks like :

@Configuration
@Profile("release")
public class CamundaConfiguration {

    @Bean
    ProcessEngineService processEngineService() {
        return BpmPlatform.getProcessEngineService();
    }
    @Bean(destroyMethod = "")
    ProcessEngine processEngine() {
        return processEngineService().getDefaultProcessEngine();
    }
    @Bean
    RepositoryService repositoryService() {
        return processEngine().getRepositoryService();
    }
    @Bean
    RuntimeService runtimeService() {
        return processEngine().getRuntimeService();
    }
    @Bean
    TaskService taskService() {
        return processEngine().getTaskService();
    }
    @Bean
    HistoryService historyService() {
        return processEngine().getHistoryService();
    }
    @Bean
    ManagementService managementService() {
        return processEngine().getManagementService();
    }
    @Bean
    SpringServletProcessApplication processApplication() {
        return new SpringServletProcessApplication();
    }
}

What is incorrect here and how can we solve this issue ?

Any idea will be appreciated.
Best Regards,

Paata Lominadze.

Hello,
Can anybody has the same problem ?

Best Regards,
Paata.

Hi Paata,

You mentioned that you use spring boot, is this correct?
Could you please check if version of Spring Boot, Camunda and Spring Boot Starter are compatible:
https://docs.camunda.org/manual/7.11/user-guide/spring-boot-integration/version-compatibility/
If they are, please share your application properties file and pom xml. The server log file will also help us to understand better what could went wrong.

Hi,

I just had the same problem. In my case, it was due to incompatible versions. I have updated camunda but it used the database of the old camunda installation. Due to db modification there was some kind of incompatibility. In my case, I just dropped the database, so camunda could recreate the tables on startup. Afterwards it worked fine. This of course, just works if it is not production. For production you have to use camunda’s db update scripts.

Nevertheless, the exception was a bit misleading and I was confused because the camunda engine was present.