Hello All,
We have a business object loaded into a business variable from the database at the start of the process.
At some point, we have a simple service task that has a single operation which sets an object property to the Integer 1:
newIssue - setStatus - Constant java.lang.Integer:1
However, this task fails with the following stack trace:
2017-06-22 12:00:00.083 -0400 SEVERE: org.bonitasoft.engine.execution.work.FailureHandlingBonitaWork THREAD_ID=221 | HOSTNAME=edo | TENANT_ID=1 | org.bonitasoft.engine.transaction.STransactionCommitException : "PROCESS_DEFINITION_ID=7930933144487046731 | PROCESS_NAME=RSM | PROCESS_VERSION=1.0 | PROCESS_INSTANCE_ID=2095 | ROOT_PROCESS_INSTANCE_ID=2095 | FLOW_NODE_DEFINITION_ID=7714527894912369835 | FLOW_NODE_INSTANCE_ID=40326 | FLOW_NODE_NAME=Tomar RSM | bitronix.tm.internal.BitronixRollbackException: RuntimeException thrown during beforeCompletion cycle caused transaction rollback" org.bonitasoft.engine.transaction.STransactionCommitException: PROCESS_DEFINITION_ID=7930933144487046731 | PROCESS_NAME=RSM | PROCESS_VERSION=1.0 | PROCESS_INSTANCE_ID=2095 | ROOT_PROCESS_INSTANCE_ID=2095 | FLOW_NODE_DEFINITION_ID=7714527894912369835 | FLOW_NODE_INSTANCE_ID=40326 | FLOW_NODE_NAME=Tomar RSM | bitronix.tm.internal.BitronixRollbackException: RuntimeException thrown during beforeCompletion cycle caused transaction rollback at org.bonitasoft.engine.transaction.JTATransactionServiceImpl.complete(JTATransactionServiceImpl.java:180) at org.bonitasoft.engine.transaction.JTATransactionServiceImpl.executeInTransaction(JTATransactionServiceImpl.java:284) at org.bonitasoft.engine.execution.work.TxBonitaWork.work(TxBonitaWork.java:53) at org.bonitasoft.engine.execution.work.LockProcessInstanceWork.work(LockProcessInstanceWork.java:79) at org.bonitasoft.engine.execution.work.failurewrapping.TxInHandleFailureWrappingWork.work(TxInHandleFailureWrappingWork.java:42) at org.bonitasoft.engine.execution.work.failurewrapping.TxInHandleFailureWrappingWork.work(TxInHandleFailureWrappingWork.java:42) at org.bonitasoft.engine.execution.work.failurewrapping.TxInHandleFailureWrappingWork.work(TxInHandleFailureWrappingWork.java:42) at org.bonitasoft.engine.execution.work.FailureHandlingBonitaWork.work(FailureHandlingBonitaWork.java:66) at org.bonitasoft.engine.work.BonitaWork.run(BonitaWork.java:56) at org.bonitasoft.engine.work.SequenceRunnableExecutor.innerRun(SequenceRunnableExecutor.java:47) at org.bonitasoft.engine.work.BonitaRunnable.run(BonitaRunnable.java:35) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:748) Caused by: bitronix.tm.internal.BitronixRollbackException: RuntimeException thrown during beforeCompletion cycle caused transaction rollback at bitronix.tm.BitronixTransaction.commit(BitronixTransaction.java:241) at bitronix.tm.BitronixTransactionManager.commit(BitronixTransactionManager.java:143) at org.bonitasoft.engine.transaction.JTATransactionServiceImpl.complete(JTATransactionServiceImpl.java:176) ... 13 more Caused by: javax.persistence.PersistenceException: error during managed flush at org.hibernate.ejb.AbstractEntityManagerImpl$CallbackExceptionMapperImpl.mapManagedFlushFailure(AbstractEntityManagerImpl.java:1515) at org.hibernate.engine.transaction.synchronization.internal.SynchronizationCallbackCoordinatorNonTrackingImpl.beforeCompletion(SynchronizationCallbackCoordinatorNonTrackingImpl.java:110) at org.hibernate.engine.transaction.synchronization.internal.RegisteredSynchronization.beforeCompletion(RegisteredSynchronization.java:53) at bitronix.tm.BitronixTransaction.fireBeforeCompletionEvent(BitronixTransaction.java:532) at bitronix.tm.BitronixTransaction.commit(BitronixTransaction.java:235) ... 15 more Caused by: java.lang.NullPointerException at org.hibernate.type.LongType.next(LongType.java:76) at org.hibernate.type.LongType.next(LongType.java:40) at org.hibernate.engine.internal.Versioning.increment(Versioning.java:130) at org.hibernate.event.internal.DefaultFlushEntityEventListener.getNextVersion(DefaultFlushEntityEventListener.java:391) at org.hibernate.event.internal.DefaultFlushEntityEventListener.scheduleUpdate(DefaultFlushEntityEventListener.java:288) at org.hibernate.event.internal.DefaultFlushEntityEventListener.onFlushEntity(DefaultFlushEntityEventListener.java:165) at org.hibernate.event.internal.AbstractFlushingEventListener.flushEntities(AbstractFlushingEventListener.java:230) at org.hibernate.event.internal.AbstractFlushingEventListener.flushEverythingToExecutions(AbstractFlushingEventListener.java:100) at org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:55) at org.hibernate.internal.SessionImpl.flush(SessionImpl.java:1159) at org.hibernate.internal.SessionImpl.managedFlush(SessionImpl.java:404) at org.hibernate.engine.transaction.synchronization.internal.SynchronizationCallbackCoordinatorNonTrackingImpl.beforeCompletion(SynchronizationCallbackCoordinatorNonTrackingImpl.java:105) ... 18 more
The server complaints about a NullPointer Exception, however the business variables is set (it’s been used in previous tasks with no problem) and the value set is a constant.
Thank you.