Optimistic Locking Exception with external task client

Hi I’m seeing below exceptions in one of our external task client

externalTaskClient is written in java and it is running in two instances

this is my externaltaskclient configuration

client = ExternalTaskClient.create().baseUrl(bpmBaseUrl)
.addInterceptor(new BasicAuthProvider(pwd)).asyncResponseTimeout(55000)
.backoffStrategy(new ExponentialBackoffStrategy(3500L, 2, 60000L)).maxTasks(1).build();

org.camunda.bpm.client.exception.NotResumedException: TASK/CLIENT-01009 Exception while completing the external task: The corresponding process instance could not be resumed. Reason: status code: 500, reason phrase: {“type”:“OptimisticLockingException”,“message”:“ENGINE-03005 Execution of ‘UPDATE VariableInstanceEntity[ad2896ca-3664-11eb-a827-0edbc94d5605]’ failed. Entity was updated by another transaction concurrently.”}

TASK/CLIENT-01009 Exception while completing the external task: The corresponding process instance could not be resumed. Reason: status code: 500, reason phrase: {“type”:“OptimisticLockingException”,“message”:“ENGINE-03005 Execution of ‘UPDATE VariableInstanceEntity[ad2896ca-3664-11eb-a827-0edbc94d5605]’ failed. Entity was updated by another transaction concurrently.”}

Hi @avinashreddy

Can you take a look at the Style Guide? It’ll help you understand how to format code correctly and also help you create questions that are easy to understand and also easier to answer :slight_smile: