AnsweredAssumed Answered

TimerEntity[XXXXXX] was updated by another transaction concurrently

Question asked by swamy2156 on Jul 4, 2013
Latest reply on Jul 10, 2013 by frederikheremans1
Hi,

I wrote  a process with timer boundary event & a service task. For every 2 minutes serviceTask will be called and send some notifications(linux box#1 where jobExecutorActivate = true)
I wrote a service to complete the human task( linux box#2 - where jobExecutorActivate = false). Occassionally while updating the task using the service which I written I am getting this error
                            "TimerEntity[XXXXXXX] was updated by another transaction concurrently"
in perticular scenarios where updating the task and timer event executed simultaniously.

box#1 processEngine configuration is as follows.

  <bean id="processEngineConfiguration" class="org.activiti.spring.SpringProcessEngineConfiguration">
    <property name="dataSource" ref="dataSource" />
    <property name="transactionManager" ref="transactionManager" />
    <property name="history" value="full" />
    <property name="databaseSchemaUpdate" value="false" />
    <property name="jobExecutorActivate" value="true" />
    <property name="jobExecutor">
      <bean class="org.activiti.engine.impl.jobexecutor.DefaultJobExecutor">
        <property name="corePoolSize" value="1"/>
        <property name="maxPoolSize" value="1"/>
      </bean>
    </property>
    <property name="jdbcPingEnabled" value="true" />
    <property name="jdbcPingQuery" value="select 1" />
    <property name="processDefinitionCacheLimit" value="20" />
    <property name="processEngineName" value="default"></property>
    <property name="customSessionFactories">
      <list>
        <bean class="com.uprr.bpm.rest.services.ldap.LDAPUserManagerFactory">
          <constructor-arg ref="ldapConnectionParams" />
        </bean>
        <bean class="com.uprr.bpm.rest.services.ldap.LDAPGroupManagerFactory">
          <constructor-arg ref="ldapConnectionParams" />
        </bean>
      </list>
    </property>
  </bean>
  <bean id="transactionManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
    <property name="dataSource" ref="dataSource" />
  </bean>

Any help will be really appreciated.

Thanks,
Swamy.

Outcomes