asyncExecutorAsyncJobLockTimeInMillis resets to 5 minutes when I override to custom time

Showing results for 
Search instead for 
Did you mean: 
Active Member II

asyncExecutorAsyncJobLockTimeInMillis resets to 5 minutes when I override to custom time

Hello all,

I am noticing the below issue sporadically in my application . I am using springboot with activiti 6. 

We have long running Jobs in each of the service tasks which could last upto 1-2 hour. Since I have like 20+ processes , I did not follow segregating the external calls to signal the User task as I end up in  creating big process workflow. I was overriding the asyncExecutorAsyncJobLockTimeInMillis  from 5 minutes to my custom time (say 3 hours ). I noticed that some of the process steps were getting picked by Async job twice or more. When I tried to trace the history of ACT_RU_JOB , I see for some steps the lock expiry time is set to 5 minutes. What could have caused this issue?

Bean that sets the custom  Lock Expiry Time:

public SpringAsyncExecutor springAsyncExecutor () {

SpringAsyncExecutor asyncExecutor = new SpringAsyncExecutor();
asyncExecutor.setTimerLockTimeInMillis(config.getMaximumProcessingTime()); // 12 hours
asyncExecutor.setAsyncJobLockTimeInMillis(config.getMaximumProcessingTime()); // 12 hours
return asyncExecutor;


Also In addition to that I set it at engine config level as well:

public SpringProcessEngineConfiguration springProcessEngineConfiguration(
@Qualifier("activitiTxMnger") PlatformTransactionManager transactionManager,
@Qualifier("springAsyncExecutor") SpringAsyncExecutor springAsyncExecutor) throws IOException {

SpringProcessEngineConfiguration engineConfig = baseSpringProcessEngineConfiguration(

engineConfig.setAsyncExecutorTimerLockTimeInMillis(config.getMaximumProcessingTime()); //12 hours
engineConfig.setAsyncExecutorAsyncJobLockTimeInMillis(config.getMaximumProcessingTime()); // 12 hours

return engineConfig;


Any help is appreciated!!