KB0171512 Long running batches and duplicate RecostarPlugin processes
KB Articles
KB Article # 171512
Topic/Category: Activiti, 4x
Issue: Duplicate processes result in error similar to:
2017-05-22 12:03:06,014 [ERROR] [pool-1-thread-7] [com.ephesoft.dcma.recostar.service.RecostarServiceImpl] – Uncaught Exception in readOCR method Batch Instance with identifier BI2B3DE is either deleted or restarted midway of processing
com.ephesoft.dcma.core.exception.BatchInstanceDeletionOrRestartException: Batch Instance with identifier BI2B3DE is either deleted or restarted midway of processing
2017-05-22 12:03:06,014 [ERROR] [pool-1-thread-7] [org.activiti.engine.impl.cmd.JobRetryCmd] – activitiy or FailedJobRetryTimerCycleValue is null in job 6d8fb14d-3f01-11e7-a02c-0025b5500a9e’. only decrementing retries.
2017-05-22 12:03:06,077 [ERROR] [pool-1-thread-7] [org.springframework.transaction.support.TransactionSynchronizationUtils] – TransactionSynchronization.afterCompletion threw exception
org.activiti.engine.ActivitiOptimisticLockingException: JobEntity [id=6d8fb14d-3f01-11e7-a02c-0025b5500a9e] was updated by another transaction concurrently
Solution:
Increase activity.restart.time in application.properties.