2 Replies Latest reply on Nov 10, 2010 8:02 AM by M -

    Could not synchronize databse problem

    Yogita Bartake Newbie

      I get the following error at a specific activity. In the my workflow the first activity is a custom where I am initializing a few variables. The next activity is a subprocess.

       

      The first activity executes properly. When subrocess starts the following error occurs and then the execution starts from the first activity and this time everything runs smoothly. This happens each time I run the workflow. Is there anything wrong the workflow is designed? Please Help!!

       

      2010-03-23 09:12:40,450 ERROR [STDERR] Mar 23, 2010 9:12:40 AM org.hibernate.event.def.AbstractFlushingEventListener performExecutions SEVERE: Could not synchronize database state with session org.hibernate.StaleObjectStateException: Row was updated or deleted by another transaction (or unsaved-value mapping was incorrect): [org.jbpm.pvm.internal.model.ExecutionImpl#1534] at org.hibernate.persister.entity.AbstractEntityPersister.check(AbstractEntityPersister.java:1792) at org.hibernate.persister.entity.AbstractEntityPersister.update(AbstractEntityPersister.java:2435) at org.hibernate.persister.entity.AbstractEntityPersister.updateOrInsert(AbstractEntityPersister.java:2335) at org.hibernate.persister.entity.AbstractEntityPersister.update(AbstractEntityPersister.java:2635) at org.hibernate.action.EntityUpdateAction.execute(EntityUpdateAction.java:115) at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279) at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:263) at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:168) at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:321) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:50) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1027) at org.jbpm.pvm.internal.model.DefaultIdGenerator.createId(DefaultIdGenerator.java:53) at org.jbpm.pvm.internal.model.ExecutionImpl.initializeProcessInstance(ExecutionImpl.java:184) at org.jbpm.pvm.internal.model.ProcessDefinitionImpl.createProcessInstance(ProcessDefinitionImpl.java:107) at org.jbpm.jpdl.internal.activity.SubProcessActivity.execute(SubProcessActivity.java:69) at org.jbpm.pvm.internal.model.op.ExecuteActivity.perform(ExecuteActivity.java:60) at org.jbpm.pvm.internal.model.ExecutionImpl.performAtomicOperationSync(ExecutionImpl.java:637) at org.jbpm.pvm.internal.model.ExecutionImpl.performAtomicOperation(ExecutionImpl.java:597) at org.jbpm.pvm.internal.model.ExecutionImpl.signal(ExecutionImpl.java:398) at org.jbpm.pvm.internal.cmd.SignalCmd.execute(SignalCmd.java:61) at org.jbpm.pvm.internal.cmd.SignalCmd.execute(SignalCmd.java:35) at org.jbpm.pvm.internal.svc.DefaultCommandService.execute(DefaultCommandService.java:42) at org.jbpm.pvm.internal.tx.StandardTransactionInterceptor.execute(StandardTransactionInterceptor.java:54) at org.jbpm.pvm.internal.svc.EnvironmentInterceptor.execute(EnvironmentInterceptor.java:46) at org.jbpm.pvm.internal.svc.RetryInterceptor.execute(RetryInterceptor.java:55) at org.jbpm.pvm.internal.svc.ExecutionServiceImpl.signalExecutionById(ExecutionServiceImpl.java:84)
        • 1. Re: Could not synchronize databse problem
          Yogita Bartake Newbie

          Any updates on this? I was looking into some other problem and now have to solve this one asap.

          Any help is appreciated!!!

          Thanks

          • 2. Re: Could not synchronize databse problem
            M - Newbie

            Did you find a solution for this?

             

            I'm getting this as well while load testing with AS 5.1.0, ESB 4.9, jBPM 3.2.8, using HSQL or MS SQL Server 2005.

             

            2010-11-10 12:02:25,799 ERROR [org.hibernate.event.def.AbstractFlushingEventListener] (JbpmJobExector:192.168.1.121:1) [Could not synchronize database state with session]
            org.hibernate.StaleObjectStateException: Row was updated or deleted by another transaction (or unsaved-value mapping was incorrect): [org.jbpm.job.ExecuteActionJob#6557]
            at org.hibernate.persister.entity.AbstractEntityPersister.check(AbstractEntityPersister.java:1792)
            at org.hibernate.persister.entity.AbstractEntityPersister.delete(AbstractEntityPersister.java:2551)
            at org.hibernate.persister.entity.AbstractEntityPersister.delete(AbstractEntityPersister.java:2725)
            at org.hibernate.action.EntityDeleteAction.execute(EntityDeleteAction.java:97)
            at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279)
            at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:263)
            at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:172)
            at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:321)
            at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:50)
            at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1027)
            at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:365)
            at org.hibernate.transaction.CacheSynchronization.beforeCompletion(CacheSynchronization.java:88)
            at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:101)
            at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:269)
            at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:89)
            at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:177)
            at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1423)
            at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:137)
            at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:75)
            at org.jboss.tm.usertx.client.ServerVMClientUserTransaction.commit(ServerVMClientUserTransaction.java:162)
            at org.jbpm.persistence.jta.JtaDbPersistenceService.commit(JtaDbPersistenceService.java:98)
            at org.jbpm.persistence.db.DbPersistenceService.endTransaction(DbPersistenceService.java:135)
            at org.jbpm.persistence.db.DbPersistenceService.close(DbPersistenceService.java:201)
            at org.jbpm.svc.Services.close(Services.java:247)
            at org.jbpm.JbpmContext.close(JbpmContext.java:131)
            at org.jbpm.job.executor.JobExecutorThread.executeJob(JobExecutorThread.java:202)
            at org.jbpm.job.executor.JobExecutorThread.run(JobExecutorThread.java:63)
            2010-11-10 12:02:25,800 WARN  [com.arjuna.ats.arjuna.logging.arjLoggerI18N] (JbpmJobExector:192.168.1.121:1) [[com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator_2] TwoPhaseCoordinator.beforeCompletion - failed for com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple@42fa7aa3]
            org.hibernate.StaleObjectStateException: Row was updated or deleted by another transaction (or unsaved-value mapping was incorrect): [org.jbpm.job.ExecuteActionJob#6557]
            at org.hibernate.persister.entity.AbstractEntityPersister.check(AbstractEntityPersister.java:1792)
            at org.hibernate.persister.entity.AbstractEntityPersister.delete(AbstractEntityPersister.java:2551)
            at org.hibernate.persister.entity.AbstractEntityPersister.delete(AbstractEntityPersister.java:2725)
            at org.hibernate.action.EntityDeleteAction.execute(EntityDeleteAction.java:97)
            at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279)
            at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:263)
            at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:172)
            at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:321)
            at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:50)
            at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1027)
            at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:365)
            at org.hibernate.transaction.CacheSynchronization.beforeCompletion(CacheSynchronization.java:88)
            at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:101)
            at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:269)
            at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:89)
            at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:177)
            at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1423)
            at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:137)
            at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:75)
            at org.jboss.tm.usertx.client.ServerVMClientUserTransaction.commit(ServerVMClientUserTransaction.java:162)
            at org.jbpm.persistence.jta.JtaDbPersistenceService.commit(JtaDbPersistenceService.java:98)
            at org.jbpm.persistence.db.DbPersistenceService.endTransaction(DbPersistenceService.java:135)
            at org.jbpm.persistence.db.DbPersistenceService.close(DbPersistenceService.java:201)
            at org.jbpm.svc.Services.close(Services.java:247)
            at org.jbpm.JbpmContext.close(JbpmContext.java:131)
            at org.jbpm.job.executor.JobExecutorThread.executeJob(JobExecutorThread.java:202)
            at org.jbpm.job.executor.JobExecutorThread.run(JobExecutorThread.java:63)
            2010-11-10 12:02:25,805 ERROR [org.jbpm.job.executor.JobExecutorThread] (JbpmJobExector:192.168.1.121:1) [exception in JbpmJobExector:192.168.1.121:1, waiting 5000 ms]
            java.lang.IllegalStateException: BaseTransaction.rollback - [com.arjuna.ats.internal.jta.transaction.arjunacore.notx] [com.arjuna.ats.internal.jta.transaction.arjunacore.notx] no transaction!
            at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.rollback(BaseTransaction.java:160)
            at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.rollback(BaseTransactionManagerDelegate.java:114)
            at org.jboss.tm.usertx.client.ServerVMClientUserTransaction.rollback(ServerVMClientUserTransaction.java:170)
            at org.jbpm.persistence.jta.JtaDbPersistenceService.rollback(JtaDbPersistenceService.java:119)
            at org.jbpm.persistence.db.DbPersistenceService.endTransaction(DbPersistenceService.java:137)
            at org.jbpm.persistence.db.DbPersistenceService.close(DbPersistenceService.java:201)
            at org.jbpm.svc.Services.close(Services.java:247)
            at org.jbpm.JbpmContext.close(JbpmContext.java:131)
            at org.jbpm.job.executor.JobExecutorThread.executeJob(JobExecutorThread.java:202)
            at org.jbpm.job.executor.JobExecutorThread.run(JobExecutorThread.java:63)

            2010-11-10 12:02:25,799 ERROR [org.hibernate.event.def.AbstractFlushingEventListener] (JbpmJobExector:192.168.1.121:1) [Could not synchronize database state with session]

            org.hibernate.StaleObjectStateException: Row was updated or deleted by another transaction (or unsaved-value mapping was incorrect): [org.jbpm.job.ExecuteActionJob#6557]

                 at org.hibernate.persister.entity.AbstractEntityPersister.check(AbstractEntityPersister.java:1792)

                 at org.hibernate.persister.entity.AbstractEntityPersister.delete(AbstractEntityPersister.java:2551)

                 at org.hibernate.persister.entity.AbstractEntityPersister.delete(AbstractEntityPersister.java:2725)

                 at org.hibernate.action.EntityDeleteAction.execute(EntityDeleteAction.java:97)

                 at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279)

                 at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:263)

                 at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:172)

                 at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:321)

                 at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:50)

                 at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1027)

                 at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:365)

                 at org.hibernate.transaction.CacheSynchronization.beforeCompletion(CacheSynchronization.java:88)

                 at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:101)

                 at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:269)

                 at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:89)

                 at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:177)

                 at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1423)

                 at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:137)

                 at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:75)

                 at org.jboss.tm.usertx.client.ServerVMClientUserTransaction.commit(ServerVMClientUserTransaction.java:162)

                 at org.jbpm.persistence.jta.JtaDbPersistenceService.commit(JtaDbPersistenceService.java:98)

                 at org.jbpm.persistence.db.DbPersistenceService.endTransaction(DbPersistenceService.java:135)

                 at org.jbpm.persistence.db.DbPersistenceService.close(DbPersistenceService.java:201)

                 at org.jbpm.svc.Services.close(Services.java:247)

                 at org.jbpm.JbpmContext.close(JbpmContext.java:131)

                 at org.jbpm.job.executor.JobExecutorThread.executeJob(JobExecutorThread.java:202)

                 at org.jbpm.job.executor.JobExecutorThread.run(JobExecutorThread.java:63)

            2010-11-10 12:02:25,800 WARN  [com.arjuna.ats.arjuna.logging.arjLoggerI18N] (JbpmJobExector:192.168.1.121:1) [[com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator_2] TwoPhaseCoordinator.beforeCompletion - failed for com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple@42fa7aa3]

            org.hibernate.StaleObjectStateException: Row was updated or deleted by another transaction (or unsaved-value mapping was incorrect): [org.jbpm.job.ExecuteActionJob#6557]

                 at org.hibernate.persister.entity.AbstractEntityPersister.check(AbstractEntityPersister.java:1792)

                 at org.hibernate.persister.entity.AbstractEntityPersister.delete(AbstractEntityPersister.java:2551)

                 at org.hibernate.persister.entity.AbstractEntityPersister.delete(AbstractEntityPersister.java:2725)

                 at org.hibernate.action.EntityDeleteAction.execute(EntityDeleteAction.java:97)

                 at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279)

                 at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:263)

                 at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:172)

                 at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:321)

                 at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:50)

                 at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1027)

                 at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:365)

                 at org.hibernate.transaction.CacheSynchronization.beforeCompletion(CacheSynchronization.java:88)

                 at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:101)

                 at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:269)

                 at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:89)

                 at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:177)

                 at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1423)

                 at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:137)

                 at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:75)

                 at org.jboss.tm.usertx.client.ServerVMClientUserTransaction.commit(ServerVMClientUserTransaction.java:162)

                 at org.jbpm.persistence.jta.JtaDbPersistenceService.commit(JtaDbPersistenceService.java:98)

                 at org.jbpm.persistence.db.DbPersistenceService.endTransaction(DbPersistenceService.java:135)

                 at org.jbpm.persistence.db.DbPersistenceService.close(DbPersistenceService.java:201)

                 at org.jbpm.svc.Services.close(Services.java:247)

                 at org.jbpm.JbpmContext.close(JbpmContext.java:131)

                 at org.jbpm.job.executor.JobExecutorThread.executeJob(JobExecutorThread.java:202)

                 at org.jbpm.job.executor.JobExecutorThread.run(JobExecutorThread.java:63)

            2010-11-10 12:02:25,805 ERROR [org.jbpm.job.executor.JobExecutorThread] (JbpmJobExector:192.168.1.121:1) [exception in JbpmJobExector:192.168.1.121:1, waiting 5000 ms]

            java.lang.IllegalStateException: BaseTransaction.rollback - [com.arjuna.ats.internal.jta.transaction.arjunacore.notx] [com.arjuna.ats.internal.jta.transaction.arjunacore.notx] no transaction!

                 at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.rollback(BaseTransaction.java:160)

                 at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.rollback(BaseTransactionManagerDelegate.java:114)

                 at org.jboss.tm.usertx.client.ServerVMClientUserTransaction.rollback(ServerVMClientUserTransaction.java:170)

                 at org.jbpm.persistence.jta.JtaDbPersistenceService.rollback(JtaDbPersistenceService.java:119)

                 at org.jbpm.persistence.db.DbPersistenceService.endTransaction(DbPersistenceService.java:137)

                 at org.jbpm.persistence.db.DbPersistenceService.close(DbPersistenceService.java:201)

                 at org.jbpm.svc.Services.close(Services.java:247)

                 at org.jbpm.JbpmContext.close(JbpmContext.java:131)

                 at org.jbpm.job.executor.JobExecutorThread.executeJob(JobExecutorThread.java:202)

                 at org.jbpm.job.executor.JobExecutorThread.run(JobExecutorThread.java:63)