camunda-community-hub / micronaut-camunda-platform-7

Integration between Micronaut and Camunda (Workflow Engine). We configure Camunda with sensible defaults, so that you can get started with minimum configuration: simply add a dependency in your Micronaut project to embed the workflow engine!
https://camunda.com/blog/2021/07/automate-any-process-on-micronaut/
Apache License 2.0
75 stars 31 forks source link

Enabling history cleanup with history: full on empty db fails Camunda startup #420

Closed datakurre closed 2 years ago

datakurre commented 2 years ago

Continuation from https://github.com/camunda-community-hub/micronaut-camunda-platform-7/issues/410

With

demo.tar.gz

the interesting configuration being

camunda:
  generic-properties:
    properties:
      history: full
      history-cleanup-enabled: true
      history-cleanup-batch-window-start-time: "22:00"
(deck@steamdeck demo)$ ./mvnw mn:run
[INFO] Scanning for projects...
[INFO] 
[INFO] --------------------------< com.example:demo >--------------------------
[INFO] Building demo 0.1
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] 
[INFO] >>> micronaut-maven-plugin:3.3.0:run (default-cli) > process-classes @ demo >>>
[WARNING] The POM for org.camunda.assert:camunda-bpm-assert:jar:7.17.0 is missing, no dependency information available
[INFO] 
[INFO] --- maven-resources-plugin:3.2.0:resources (default-resources) @ demo ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Using 'UTF-8' encoding to copy filtered properties files.
[INFO] Copying 2 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.10.1:compile (default-compile) @ demo ---
[INFO] Nothing to compile - all classes are up to date
[INFO] 
[INFO] <<< micronaut-maven-plugin:3.3.0:run (default-cli) < process-classes @ demo <<<
[INFO] 
[INFO] 
[INFO] --- micronaut-maven-plugin:3.3.0:run (default-cli) @ demo ---
 __  __ _                                  _   
|  \/  (_) ___ _ __ ___  _ __   __ _ _   _| |_ 
| |\/| | |/ __| '__/ _ \| '_ \ / _` | | | | __|
| |  | | | (__| | | (_) | | | | (_| | |_| | |_ 
|_|  |_|_|\___|_|  \___/|_| |_|\__,_|\__,_|\__|
  Micronaut (v3.5.0)

21:54:20.373 [main] INFO  com.zaxxer.hikari.HikariDataSource - HikariPool-1 - Starting...
21:54:20.573 [main] INFO  com.zaxxer.hikari.HikariDataSource - HikariPool-1 - Start completed.
21:54:21.067 [main] INFO  i.n.m.c.b.f.MnTelemetryRegistry - Server runtime version: vendor=netty, version=netty-4.1.77.Final
21:54:21.165 [main] INFO  i.n.m.c.b.f.MnProcessEngineConfiguration - Registering process engine plugins: []
21:54:21.188 [main] INFO  i.n.m.c.b.f.ProcessEngineFactory - Camunda version: 7.17.0
21:54:21.188 [main] INFO  i.n.m.c.b.f.ProcessEngineFactory - Building process engine connected to jdbc:h2:mem:default;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE
21:54:21.420 [main] INFO  org.camunda.feel.FeelEngine - Engine created. [value-mapper: CompositeValueMapper(List(org.camunda.feel.impl.JavaValueMapper@79d9214d)), function-provider: org.camunda.bpm.dmn.feel.impl.scala.function.CustomFunctionTransformer@242a209e, clock: SystemClock, configuration: Configuration(false)]
21:54:22.652 [main] WARN  org.camunda.bpm.engine - ENGINE-00009 Could not determine local IP address for generating a host name
java.net.UnknownHostException: steamdeck: steamdeck: Name or service not known
        at java.base/java.net.InetAddress.getLocalHost(InetAddress.java:1647)
        at org.camunda.bpm.engine.impl.history.event.SimpleIpBasedProvider.getHostname(SimpleIpBasedProvider.java:36)
        at org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl.initHostName(ProcessEngineConfigurationImpl.java:2411)
        at org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl.init(ProcessEngineConfigurationImpl.java:1075)
        at org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl.buildProcessEngine(ProcessEngineConfigurationImpl.java:1016)
        at info.novatec.micronaut.camunda.bpm.feature.ProcessEngineFactory.lambda$processEngine$0(ProcessEngineFactory.java:54)
        at io.micronaut.transaction.support.AbstractSynchronousStateTransactionManager.execute(AbstractSynchronousStateTransactionManager.java:146)
        at io.micronaut.transaction.support.AbstractSynchronousStateTransactionManager.executeWrite(AbstractSynchronousStateTransactionManager.java:167)
        at io.micronaut.transaction.support.AbstractSynchronousTransactionManager.executeWrite(AbstractSynchronousTransactionManager.java:138)
        at info.novatec.micronaut.camunda.bpm.feature.ProcessEngineFactory.processEngine(ProcessEngineFactory.java:53)
        at info.novatec.micronaut.camunda.bpm.feature.$ProcessEngineFactory$ProcessEngine0$Definition.build(Unknown Source)
        at io.micronaut.context.DefaultBeanContext.resolveByBeanFactory(DefaultBeanContext.java:2331)
        at io.micronaut.context.DefaultBeanContext.doCreateBean(DefaultBeanContext.java:2282)
        at io.micronaut.context.DefaultBeanContext.doCreateBean(DefaultBeanContext.java:2228)
        at io.micronaut.context.DefaultBeanContext.createRegistration(DefaultBeanContext.java:2988)
        at io.micronaut.context.SingletonScope.getOrCreate(SingletonScope.java:80)
        at io.micronaut.context.DefaultBeanContext.findOrCreateSingletonBeanRegistration(DefaultBeanContext.java:2890)
        at io.micronaut.context.DefaultBeanContext.resolveBeanRegistration(DefaultBeanContext.java:2851)
        at io.micronaut.context.DefaultBeanContext.resolveBeanRegistration(DefaultBeanContext.java:2772)
        at io.micronaut.context.DefaultBeanContext.getBean(DefaultBeanContext.java:1594)
        at io.micronaut.inject.provider.BeanProviderDefinition$1.get(BeanProviderDefinition.java:80)
        at info.novatec.micronaut.camunda.bpm.feature.initialization.InitProcessEngineService.onEvent(InitProcessEngineService.java:66)
        at info.novatec.micronaut.camunda.bpm.feature.initialization.$InitProcessEngineService$Definition$Exec.dispatch(Unknown Source)
        at io.micronaut.context.AbstractExecutableMethodsDefinition$DispatchedExecutableMethod.invoke(AbstractExecutableMethodsDefinition.java:378)
        at io.micronaut.context.DefaultBeanContext$BeanExecutionHandle.invoke(DefaultBeanContext.java:3794)
        at io.micronaut.aop.chain.AdapterIntroduction.intercept(AdapterIntroduction.java:83)
        at io.micronaut.aop.chain.MethodInterceptorChain.proceed(MethodInterceptorChain.java:137)
        at info.novatec.micronaut.camunda.bpm.feature.initialization.InitProcessEngineService$ApplicationEventListener$onEvent1$Intercepted.onApplicationEvent(Unknown Source)
        at io.micronaut.context.event.ApplicationEventPublisherFactory.notifyEventListeners(ApplicationEventPublisherFactory.java:262)
        at io.micronaut.context.event.ApplicationEventPublisherFactory.access$200(ApplicationEventPublisherFactory.java:60)
        at io.micronaut.context.event.ApplicationEventPublisherFactory$2.publishEvent(ApplicationEventPublisherFactory.java:229)
        at io.micronaut.http.server.netty.NettyHttpServer.fireStartupEvents(NettyHttpServer.java:558)
        at io.micronaut.http.server.netty.NettyHttpServer.start(NettyHttpServer.java:301)
        at io.micronaut.http.server.netty.NettyHttpServer.start(NettyHttpServer.java:112)
        at io.micronaut.runtime.Micronaut.lambda$start$2(Micronaut.java:78)
        at java.base/java.util.Optional.ifPresent(Optional.java:178)
        at io.micronaut.runtime.Micronaut.start(Micronaut.java:76)
        at io.micronaut.runtime.Micronaut.run(Micronaut.java:320)
        at io.micronaut.runtime.Micronaut.run(Micronaut.java:306)
        at com.example.Application.main(Application.java:7)
Caused by: java.net.UnknownHostException: steamdeck: Name or service not known
        at java.base/java.net.Inet6AddressImpl.lookupAllHostAddr(Native Method)
        at java.base/java.net.InetAddress$PlatformNameService.lookupAllHostAddr(InetAddress.java:933)
        at java.base/java.net.InetAddress.getAddressesFromNameService(InetAddress.java:1519)
        at java.base/java.net.InetAddress$NameServiceAddresses.get(InetAddress.java:852)
        at java.base/java.net.InetAddress.getAllByName0(InetAddress.java:1509)
        at java.base/java.net.InetAddress.getLocalHost(InetAddress.java:1642)
        ... 39 common frames omitted
21:54:22.955 [main] INFO  org.camunda.bpm.connect - CNCT-01004 Discovered provider for connector id 'http-connector' and class 'org.camunda.connect.httpclient.impl.HttpConnectorImpl': 'org.camunda.connect.httpclient.impl.HttpConnectorProviderImpl'
21:54:22.959 [main] INFO  org.camunda.bpm.connect - CNCT-01004 Discovered provider for connector id 'soap-http-connector' and class 'org.camunda.connect.httpclient.soap.impl.SoapHttpConnectorImpl': 'org.camunda.connect.httpclient.soap.impl.SoapHttpConnectorProviderImpl'
21:54:23.202 [main] INFO  org.camunda.bpm.engine.persistence - ENGINE-03016 Performing database operation 'create' on component 'engine' with resource 'org/camunda/bpm/engine/db/create/activiti.h2.create.engine.sql'
21:54:23.271 [main] INFO  org.camunda.bpm.engine.persistence - ENGINE-03016 Performing database operation 'create' on component 'history' with resource 'org/camunda/bpm/engine/db/create/activiti.h2.create.history.sql'
21:54:23.294 [main] INFO  org.camunda.bpm.engine.persistence - ENGINE-03016 Performing database operation 'create' on component 'identity' with resource 'org/camunda/bpm/engine/db/create/activiti.h2.create.identity.sql'
21:54:23.308 [main] INFO  org.camunda.bpm.engine.persistence - ENGINE-03016 Performing database operation 'create' on component 'decision.engine' with resource 'org/camunda/bpm/engine/db/create/activiti.h2.create.decision.engine.sql'
21:54:23.326 [main] INFO  org.camunda.bpm.engine.persistence - ENGINE-03016 Performing database operation 'create' on component 'decision.history' with resource 'org/camunda/bpm/engine/db/create/activiti.h2.create.decision.history.sql'
21:54:23.353 [main] INFO  org.camunda.bpm.engine.persistence - ENGINE-03067 No history level property found in database
21:54:23.353 [main] INFO  org.camunda.bpm.engine.persistence - ENGINE-03065 Creating historyLevel property in database for level: HistoryLevelFull(name=full, id=3)
21:54:23.477 [main] ERROR org.camunda.bpm.engine.context - ENGINE-16004 Exception while closing command context: An exception occurred in the persistence layer. Please check the server logs for a detailed message and the entire exception stack trace.
org.camunda.bpm.engine.ProcessEngineException: An exception occurred in the persistence layer. Please check the server logs for a detailed message and the entire exception stack trace.
        at org.camunda.bpm.engine.impl.util.ExceptionUtil.wrapPersistenceException(ExceptionUtil.java:263)
        at org.camunda.bpm.engine.impl.db.EnginePersistenceLogger.flushDbOperationUnexpectedException(EnginePersistenceLogger.java:680)
        at org.camunda.bpm.engine.impl.db.entitymanager.DbEntityManager.flushDbOperations(DbEntityManager.java:344)
        at org.camunda.bpm.engine.impl.db.entitymanager.DbEntityManager.flushDbOperationManager(DbEntityManager.java:323)
        at org.camunda.bpm.engine.impl.db.entitymanager.DbEntityManager.flush(DbEntityManager.java:295)
        at org.camunda.bpm.engine.impl.interceptor.CommandContext.flushSessions(CommandContext.java:272)
        at org.camunda.bpm.engine.impl.interceptor.CommandContext.close(CommandContext.java:188)
        at org.camunda.bpm.engine.impl.interceptor.CommandContextInterceptor.execute(CommandContextInterceptor.java:119)
        at info.novatec.micronaut.camunda.bpm.feature.tx.MnTransactionInterceptor.lambda$execute$0(MnTransactionInterceptor.java:44)
        at io.micronaut.transaction.support.AbstractSynchronousStateTransactionManager.execute(AbstractSynchronousStateTransactionManager.java:146)
        at io.micronaut.transaction.support.AbstractSynchronousTransactionManager.execute(AbstractSynchronousTransactionManager.java:128)
        at info.novatec.micronaut.camunda.bpm.feature.tx.MnTransactionInterceptor.execute(MnTransactionInterceptor.java:44)
        at org.camunda.bpm.engine.impl.interceptor.ProcessApplicationContextInterceptor.execute(ProcessApplicationContextInterceptor.java:70)
        at org.camunda.bpm.engine.impl.interceptor.CommandCounterInterceptor.execute(CommandCounterInterceptor.java:35)
        at org.camunda.bpm.engine.impl.interceptor.LogInterceptor.execute(LogInterceptor.java:33)
        at org.camunda.bpm.engine.impl.ProcessEngineImpl.executeSchemaOperations(ProcessEngineImpl.java:151)
        at org.camunda.bpm.engine.impl.ProcessEngineImpl.<init>(ProcessEngineImpl.java:110)
        at org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl.buildProcessEngine(ProcessEngineConfigurationImpl.java:1017)
        at info.novatec.micronaut.camunda.bpm.feature.ProcessEngineFactory.lambda$processEngine$0(ProcessEngineFactory.java:54)
        at io.micronaut.transaction.support.AbstractSynchronousStateTransactionManager.execute(AbstractSynchronousStateTransactionManager.java:146)
        at io.micronaut.transaction.support.AbstractSynchronousStateTransactionManager.executeWrite(AbstractSynchronousStateTransactionManager.java:167)
        at io.micronaut.transaction.support.AbstractSynchronousTransactionManager.executeWrite(AbstractSynchronousTransactionManager.java:138)
        at info.novatec.micronaut.camunda.bpm.feature.ProcessEngineFactory.processEngine(ProcessEngineFactory.java:53)
        at info.novatec.micronaut.camunda.bpm.feature.$ProcessEngineFactory$ProcessEngine0$Definition.build(Unknown Source)
        at io.micronaut.context.DefaultBeanContext.resolveByBeanFactory(DefaultBeanContext.java:2331)
        at io.micronaut.context.DefaultBeanContext.doCreateBean(DefaultBeanContext.java:2282)
        at io.micronaut.context.DefaultBeanContext.doCreateBean(DefaultBeanContext.java:2228)
        at io.micronaut.context.DefaultBeanContext.createRegistration(DefaultBeanContext.java:2988)
        at io.micronaut.context.SingletonScope.getOrCreate(SingletonScope.java:80)
        at io.micronaut.context.DefaultBeanContext.findOrCreateSingletonBeanRegistration(DefaultBeanContext.java:2890)
        at io.micronaut.context.DefaultBeanContext.resolveBeanRegistration(DefaultBeanContext.java:2851)
        at io.micronaut.context.DefaultBeanContext.resolveBeanRegistration(DefaultBeanContext.java:2772)
        at io.micronaut.context.DefaultBeanContext.getBean(DefaultBeanContext.java:1594)
        at io.micronaut.inject.provider.BeanProviderDefinition$1.get(BeanProviderDefinition.java:80)
        at info.novatec.micronaut.camunda.bpm.feature.initialization.InitProcessEngineService.onEvent(InitProcessEngineService.java:66)
        at info.novatec.micronaut.camunda.bpm.feature.initialization.$InitProcessEngineService$Definition$Exec.dispatch(Unknown Source)
        at io.micronaut.context.AbstractExecutableMethodsDefinition$DispatchedExecutableMethod.invoke(AbstractExecutableMethodsDefinition.java:378)
        at io.micronaut.context.DefaultBeanContext$BeanExecutionHandle.invoke(DefaultBeanContext.java:3794)
        at io.micronaut.aop.chain.AdapterIntroduction.intercept(AdapterIntroduction.java:83)
        at io.micronaut.aop.chain.MethodInterceptorChain.proceed(MethodInterceptorChain.java:137)
        at info.novatec.micronaut.camunda.bpm.feature.initialization.InitProcessEngineService$ApplicationEventListener$onEvent1$Intercepted.onApplicationEvent(Unknown Source)
        at io.micronaut.context.event.ApplicationEventPublisherFactory.notifyEventListeners(ApplicationEventPublisherFactory.java:262)
        at io.micronaut.context.event.ApplicationEventPublisherFactory.access$200(ApplicationEventPublisherFactory.java:60)
        at io.micronaut.context.event.ApplicationEventPublisherFactory$2.publishEvent(ApplicationEventPublisherFactory.java:229)
        at io.micronaut.http.server.netty.NettyHttpServer.fireStartupEvents(NettyHttpServer.java:558)
        at io.micronaut.http.server.netty.NettyHttpServer.start(NettyHttpServer.java:301)
        at io.micronaut.http.server.netty.NettyHttpServer.start(NettyHttpServer.java:112)
        at io.micronaut.runtime.Micronaut.lambda$start$2(Micronaut.java:78)
        at java.base/java.util.Optional.ifPresent(Optional.java:178)
        at io.micronaut.runtime.Micronaut.start(Micronaut.java:76)
        at io.micronaut.runtime.Micronaut.run(Micronaut.java:320)
        at io.micronaut.runtime.Micronaut.run(Micronaut.java:306)
        at com.example.Application.main(Application.java:7)
Caused by: org.camunda.bpm.engine.ProcessEngineException: ENGINE-03083 Unexpected exception while executing database operations with message '
### Error updating database.  Cause: java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for insertHistoricJobLogEvent
### Cause: java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for insertHistoricJobLogEvent'. Flush summary: 
 [
  INSERT PropertyEntity[camunda.installation.id]
  INSERT PropertyEntity[camunda.telemetry.enabled]
  INSERT HistoricJobLogEventEntity[101c839f-f3ef-11ec-be06-90e86874d763]
  INSERT EverLivingJobEntity[101afcfe-f3ef-11ec-be06-90e86874d763]
]
        at org.camunda.bpm.engine.impl.db.EnginePersistenceLogger.flushDbOperationUnexpectedException(EnginePersistenceLogger.java:679)
        ... 51 common frames omitted
Caused by: org.apache.ibatis.exceptions.PersistenceException: 
### Error updating database.  Cause: java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for insertHistoricJobLogEvent
### Cause: java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for insertHistoricJobLogEvent
        at org.apache.ibatis.exceptions.ExceptionFactory.wrapException(ExceptionFactory.java:30)
        at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:199)
        at org.apache.ibatis.session.defaults.DefaultSqlSession.insert(DefaultSqlSession.java:184)
        at org.camunda.bpm.engine.impl.db.sql.DbSqlSession.executeInsertEntity(DbSqlSession.java:359)
        at org.camunda.bpm.engine.impl.db.sql.DbSqlSession.insertEntity(DbSqlSession.java:353)
        at org.camunda.bpm.engine.impl.db.AbstractPersistenceSession.executeDbOperation(AbstractPersistenceSession.java:44)
        at org.camunda.bpm.engine.impl.db.sql.BatchDbSqlSession.executeDbOperations(BatchDbSqlSession.java:62)
        at org.camunda.bpm.engine.impl.db.entitymanager.DbEntityManager.flushDbOperations(DbEntityManager.java:341)
        ... 50 common frames omitted
Caused by: java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for insertHistoricJobLogEvent
        at org.apache.ibatis.session.Configuration$StrictMap.get(Configuration.java:1031)
        at org.apache.ibatis.session.Configuration.getMappedStatement(Configuration.java:821)
        at org.apache.ibatis.session.Configuration.getMappedStatement(Configuration.java:814)
        at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:196)
        ... 56 common frames omitted
21:54:23.491 [main] ERROR io.micronaut.runtime.Micronaut - Error starting Micronaut server: Error instantiating bean of type  [org.camunda.bpm.engine.ProcessEngine]

Message: An exception occurred in the persistence layer. Please check the server logs for a detailed message and the entire exception stack trace.
Path Taken: ProcessEngine.processEngine(ProcessEngineConfiguration processEngineConfiguration,CamundaVersion camundaVersion,SynchronousTransactionManager transactionManager,BasicJdbcConfiguration basicJdbcConfiguration,ParallelInitializationService parallelInitializationService)
io.micronaut.context.exceptions.BeanInstantiationException: Error instantiating bean of type  [org.camunda.bpm.engine.ProcessEngine]

Message: An exception occurred in the persistence layer. Please check the server logs for a detailed message and the entire exception stack trace.
Path Taken: ProcessEngine.processEngine(ProcessEngineConfiguration processEngineConfiguration,CamundaVersion camundaVersion,SynchronousTransactionManager transactionManager,BasicJdbcConfiguration basicJdbcConfiguration,ParallelInitializationService parallelInitializationService)
        at io.micronaut.context.DefaultBeanContext.resolveByBeanFactory(DefaultBeanContext.java:2344)
        at io.micronaut.context.DefaultBeanContext.doCreateBean(DefaultBeanContext.java:2282)
        at io.micronaut.context.DefaultBeanContext.doCreateBean(DefaultBeanContext.java:2228)
        at io.micronaut.context.DefaultBeanContext.createRegistration(DefaultBeanContext.java:2988)
        at io.micronaut.context.SingletonScope.getOrCreate(SingletonScope.java:80)
        at io.micronaut.context.DefaultBeanContext.findOrCreateSingletonBeanRegistration(DefaultBeanContext.java:2890)
        at io.micronaut.context.DefaultBeanContext.resolveBeanRegistration(DefaultBeanContext.java:2851)
        at io.micronaut.context.DefaultBeanContext.resolveBeanRegistration(DefaultBeanContext.java:2772)
        at io.micronaut.context.DefaultBeanContext.getBean(DefaultBeanContext.java:1594)
        at io.micronaut.inject.provider.BeanProviderDefinition$1.get(BeanProviderDefinition.java:80)
        at info.novatec.micronaut.camunda.bpm.feature.initialization.InitProcessEngineService.onEvent(InitProcessEngineService.java:66)
        at info.novatec.micronaut.camunda.bpm.feature.initialization.$InitProcessEngineService$Definition$Exec.dispatch(Unknown Source)
        at io.micronaut.context.AbstractExecutableMethodsDefinition$DispatchedExecutableMethod.invoke(AbstractExecutableMethodsDefinition.java:378)
        at io.micronaut.context.DefaultBeanContext$BeanExecutionHandle.invoke(DefaultBeanContext.java:3794)
        at io.micronaut.aop.chain.AdapterIntroduction.intercept(AdapterIntroduction.java:83)
        at io.micronaut.aop.chain.MethodInterceptorChain.proceed(MethodInterceptorChain.java:137)
        at info.novatec.micronaut.camunda.bpm.feature.initialization.InitProcessEngineService$ApplicationEventListener$onEvent1$Intercepted.onApplicationEvent(Unknown Source)
        at io.micronaut.context.event.ApplicationEventPublisherFactory.notifyEventListeners(ApplicationEventPublisherFactory.java:262)
        at io.micronaut.context.event.ApplicationEventPublisherFactory.access$200(ApplicationEventPublisherFactory.java:60)
        at io.micronaut.context.event.ApplicationEventPublisherFactory$2.publishEvent(ApplicationEventPublisherFactory.java:229)
        at io.micronaut.http.server.netty.NettyHttpServer.fireStartupEvents(NettyHttpServer.java:558)
        at io.micronaut.http.server.netty.NettyHttpServer.start(NettyHttpServer.java:301)
        at io.micronaut.http.server.netty.NettyHttpServer.start(NettyHttpServer.java:112)
        at io.micronaut.runtime.Micronaut.lambda$start$2(Micronaut.java:78)
        at java.base/java.util.Optional.ifPresent(Optional.java:178)
        at io.micronaut.runtime.Micronaut.start(Micronaut.java:76)
        at io.micronaut.runtime.Micronaut.run(Micronaut.java:320)
        at io.micronaut.runtime.Micronaut.run(Micronaut.java:306)
        at com.example.Application.main(Application.java:7)
Caused by: org.camunda.bpm.engine.ProcessEngineException: An exception occurred in the persistence layer. Please check the server logs for a detailed message and the entire exception stack trace.
        at org.camunda.bpm.engine.impl.util.ExceptionUtil.wrapPersistenceException(ExceptionUtil.java:263)
        at org.camunda.bpm.engine.impl.db.EnginePersistenceLogger.flushDbOperationUnexpectedException(EnginePersistenceLogger.java:680)
        at org.camunda.bpm.engine.impl.db.entitymanager.DbEntityManager.flushDbOperations(DbEntityManager.java:344)
        at org.camunda.bpm.engine.impl.db.entitymanager.DbEntityManager.flushDbOperationManager(DbEntityManager.java:323)
        at org.camunda.bpm.engine.impl.db.entitymanager.DbEntityManager.flush(DbEntityManager.java:295)
        at org.camunda.bpm.engine.impl.interceptor.CommandContext.flushSessions(CommandContext.java:272)
        at org.camunda.bpm.engine.impl.interceptor.CommandContext.close(CommandContext.java:188)
        at org.camunda.bpm.engine.impl.interceptor.CommandContextInterceptor.execute(CommandContextInterceptor.java:119)
        at info.novatec.micronaut.camunda.bpm.feature.tx.MnTransactionInterceptor.lambda$execute$0(MnTransactionInterceptor.java:44)
        at io.micronaut.transaction.support.AbstractSynchronousStateTransactionManager.execute(AbstractSynchronousStateTransactionManager.java:146)
        at io.micronaut.transaction.support.AbstractSynchronousTransactionManager.execute(AbstractSynchronousTransactionManager.java:128)
        at info.novatec.micronaut.camunda.bpm.feature.tx.MnTransactionInterceptor.execute(MnTransactionInterceptor.java:44)
        at org.camunda.bpm.engine.impl.interceptor.ProcessApplicationContextInterceptor.execute(ProcessApplicationContextInterceptor.java:70)
        at org.camunda.bpm.engine.impl.interceptor.CommandCounterInterceptor.execute(CommandCounterInterceptor.java:35)
        at org.camunda.bpm.engine.impl.interceptor.LogInterceptor.execute(LogInterceptor.java:33)
        at org.camunda.bpm.engine.impl.ProcessEngineImpl.executeSchemaOperations(ProcessEngineImpl.java:151)
        at org.camunda.bpm.engine.impl.ProcessEngineImpl.<init>(ProcessEngineImpl.java:110)
        at org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl.buildProcessEngine(ProcessEngineConfigurationImpl.java:1017)
        at info.novatec.micronaut.camunda.bpm.feature.ProcessEngineFactory.lambda$processEngine$0(ProcessEngineFactory.java:54)
        at io.micronaut.transaction.support.AbstractSynchronousStateTransactionManager.execute(AbstractSynchronousStateTransactionManager.java:146)
        at io.micronaut.transaction.support.AbstractSynchronousStateTransactionManager.executeWrite(AbstractSynchronousStateTransactionManager.java:167)
        at io.micronaut.transaction.support.AbstractSynchronousTransactionManager.executeWrite(AbstractSynchronousTransactionManager.java:138)
        at info.novatec.micronaut.camunda.bpm.feature.ProcessEngineFactory.processEngine(ProcessEngineFactory.java:53)
        at info.novatec.micronaut.camunda.bpm.feature.$ProcessEngineFactory$ProcessEngine0$Definition.build(Unknown Source)
        at io.micronaut.context.DefaultBeanContext.resolveByBeanFactory(DefaultBeanContext.java:2331)
        ... 28 common frames omitted
Caused by: org.camunda.bpm.engine.ProcessEngineException: ENGINE-03083 Unexpected exception while executing database operations with message '
### Error updating database.  Cause: java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for insertHistoricJobLogEvent
### Cause: java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for insertHistoricJobLogEvent'. Flush summary: 
 [
  INSERT PropertyEntity[camunda.installation.id]
  INSERT PropertyEntity[camunda.telemetry.enabled]
  INSERT HistoricJobLogEventEntity[101c839f-f3ef-11ec-be06-90e86874d763]
  INSERT EverLivingJobEntity[101afcfe-f3ef-11ec-be06-90e86874d763]
]
        at org.camunda.bpm.engine.impl.db.EnginePersistenceLogger.flushDbOperationUnexpectedException(EnginePersistenceLogger.java:679)
        ... 51 common frames omitted
Caused by: org.apache.ibatis.exceptions.PersistenceException: 
### Error updating database.  Cause: java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for insertHistoricJobLogEvent
### Cause: java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for insertHistoricJobLogEvent
        at org.apache.ibatis.exceptions.ExceptionFactory.wrapException(ExceptionFactory.java:30)
        at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:199)
        at org.apache.ibatis.session.defaults.DefaultSqlSession.insert(DefaultSqlSession.java:184)
        at org.camunda.bpm.engine.impl.db.sql.DbSqlSession.executeInsertEntity(DbSqlSession.java:359)
        at org.camunda.bpm.engine.impl.db.sql.DbSqlSession.insertEntity(DbSqlSession.java:353)
        at org.camunda.bpm.engine.impl.db.AbstractPersistenceSession.executeDbOperation(AbstractPersistenceSession.java:44)
        at org.camunda.bpm.engine.impl.db.sql.BatchDbSqlSession.executeDbOperations(BatchDbSqlSession.java:62)
        at org.camunda.bpm.engine.impl.db.entitymanager.DbEntityManager.flushDbOperations(DbEntityManager.java:341)
        ... 50 common frames omitted
Caused by: java.lang.IllegalArgumentException: Mapped Statements collection does not contain value for insertHistoricJobLogEvent
        at org.apache.ibatis.session.Configuration$StrictMap.get(Configuration.java:1031)
        at org.apache.ibatis.session.Configuration.getMappedStatement(Configuration.java:821)
        at org.apache.ibatis.session.Configuration.getMappedStatement(Configuration.java:814)
        at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:196)
        ... 56 common frames omitted
tobiasschaefer commented 2 years ago

Hi @datakurre ,

Release 2.8.1 should fix your issue and will be available on Maven Central within about 15 minutes.

Please report back shortly if your issue is resolved. Thanks.