Dear All,
We are using embedded camunda which was working fine before. We recently change datasource configuration through jndi and after that changes we are facing issue as as below…
Any help is appreciated… Thanks in advance
ERROR context:156 - ENGINE-16004 Exception while closing command context: ENGINE-03051 There was an exception while invoking the TaskListener. Message: 'Exception while invoking TaskListener: Pre-bound JDBC Connection found! JpaTransactionManager does not support running within DataSourceTransactionManager if told to manage the DataSource itself. It is recommended to use a single JpaTransactionManager for all transactions on a single DataSource, no matter whether JPA or JDBC access.'
org.camunda.bpm.engine.ProcessEngineException: ENGINE-03051 There was an exception while invoking the TaskListener. Message: ‘Exception while invoking TaskListener: Pre-bound JDBC Connection found! JpaTransactionManager does not support running within DataSourceTransactionManager if told to manage the DataSource itself. It is recommended to use a single JpaTransactionManager for all transactions on a single DataSource, no matter whether JPA or JDBC access.’
at org.camunda.bpm.engine.impl.db.EnginePersistenceLogger.invokeTaskListenerException(EnginePersistenceLogger.java:446)
at org.camunda.bpm.engine.impl.persistence.entity.TaskEntity.fireEvent(TaskEntity.java:960)
at org.camunda.bpm.engine.impl.persistence.entity.TaskEntity.setAssignee(TaskEntity.java:861)
at org.camunda.bpm.engine.impl.persistence.entity.TaskEntity.delegate(TaskEntity.java:359)
at org.camunda.bpm.engine.impl.cmd.DelegateTaskCmd.execute(DelegateTaskCmd.java:52)
at org.camunda.bpm.engine.impl.interceptor.CommandExecutorImpl.execute(CommandExecutorImpl.java:24)
at org.camunda.bpm.engine.impl.interceptor.Command
Here is my applicationContext.xml
<?xml version="1.0" encoding="UTF-8"?><!-- Commented to implement JNDI - end -->
<bean id="transactionManager"
class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
<property name="dataSource" ref="dataSourceCamunda" />
</bean>
<bean id="processEngineConfiguration"
class="org.camunda.bpm.engine.spring.SpringProcessEngineConfiguration">
<property name="processEngineName" value="default" />
<property name="dataSource" ref="dataSourceCamunda" />
<property name="transactionManager" ref="transactionManager" />
<property name="databaseSchemaUpdate" value="false" />
<property name="jdbcBatchProcessing" value="false" /><!-- Added
by Apar : https://forum.camunda.io/t/fresh-installation-fails-on-startup-oracle-12c/6259/2 -->
<property name="jobExecutorActivate" value="true" />
<property name="metricsEnabled" value="false" /><!-- Added for
Meter log error : https://docs.camunda.org/manual/7.8/user-guide/process-engine/metrics/ -->
<property name="jobExecutorDeploymentAware" value="true"/>
<property name="history" value="audit" />
<property name="processEnginePlugins">
<list>
<!--<ref bean="ldapIdentityProviderPlugin" /> -->
<!--<ref bean="administratorAuthorizationPlugin" /> -->
<bean id="spinPlugin"
class="org.camunda.spin.plugin.impl.SpinProcessEnginePlugin" />
<bean id="connectPlugin"
class="org.camunda.connect.plugin.impl.ConnectProcessEnginePlugin" />
</list>
</property>
</bean>
<bean id="processEngine"
class="org.camunda.bpm.engine.spring.ProcessEngineFactoryBean">
<property name="processEngineConfiguration"
ref="processEngineConfiguration" />
</bean>
<bean id="ldapIdentityProviderPlugin"
class="org.camunda.bpm.identity.impl.ldap.plugin.LdapIdentityProviderPlugin">
<!--<property name="serverUrl" value="******"
/> -->
<property name="serverUrl"
value="*********************" />
<property name="baseDn" value="dc=*********,dc=**" />
<property name="managerDn" value="" />
<property name="managerPassword" value="" />
<property name="userSearchBase" value="cn=users" />
<property name="userSearchFilter"
value="(objectclass=person)" />
<property name="userIdAttribute" value="uid" />
<property name="userFirstnameAttribute" value="cn" />
<property name="userLastnameAttribute" value="sn" />
<property name="userEmailAttribute" value="mail" />
<property name="userPasswordAttribute" value="userPassword" />
<property name="groupSearchBase"
value="cn=DubaiCustomGroups,cn=groups" />
<property name="groupSearchFilter"
value="(objectclass=orclGroup)" />
<property name="groupIdAttribute" value="uid" />
<property name="groupNameAttribute" value="cn" />
<property name="groupMemberAttribute" value="uniquemember" />
</bean>
<!--<bean id="administratorAuthorizationPlugin" class="org.camunda.bpm.engine.impl.plugin.AdministratorAuthorizationPlugin">
<property name="administratorUserName" value="admin" /> </bean> -->
<bean id="administratorAuthorizationPlugin"
class="org.camunda.bpm.engine.impl.plugin.AdministratorAuthorizationPlugin">
<property name="administratorGroupName"
value="*************" />
</bean>
<bean id="repositoryService" factory-bean="processEngine"
factory-method="getRepositoryService" />
<bean id="runtimeService" factory-bean="processEngine"
factory-method="getRuntimeService" />
<bean id="taskService" factory-bean="processEngine"
factory-method="getTaskService" />
<bean id="historyService" factory-bean="processEngine"
factory-method="getHistoryService" />
<bean id="managementService" factory-bean="processEngine"
factory-method="getManagementService" />
<bean id="identityService" factory-bean="processEngine"
factory-method="getIdentityService" />
<!-- JNDI Config start -->
<jee:jndi-lookup id="dataSourceCamunda" jndi-name="jdbc/camunda_ds"/>
<!-- JNDI Config end -->