You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Bug description
Unlike the JdbcJobExecutionDao, the MongoJobExecutionDao is not "upgrading" the status of the jobExecution that was passed in. This can cause behavior where a job status can go from STOPPING back to STARTED by an asynchronous update.
Environment
Spring Batch version: 5.2.1
Java version:17.0.8
which database you use: Mongo 8.0.1
Steps to reproduce
Steps to reproduce the issue:
Start a Job using JobLauncher
Attempt to stop the job using JobOperator::stop
Verify the status in the jobExecution is updated to STOPPING via the JobExplorer
Wait for end of step to update JobExecution
Verify the status in the jobExecution is downgraded to STARTED via the JobExplorer
Expected behavior
I would expect the status to not be allowed to downgrade because that is the behavior of the JDBC implementation.
The text was updated successfully, but these errors were encountered:
I was able to fix this locally by modifying the synchronizeStatus method to either upgrade the local jobExecution status or update the status in database:
Bug description
Unlike the JdbcJobExecutionDao, the MongoJobExecutionDao is not "upgrading" the status of the jobExecution that was passed in. This can cause behavior where a job status can go from STOPPING back to STARTED by an asynchronous update.
Environment
Spring Batch version: 5.2.1
Java version:17.0.8
which database you use: Mongo 8.0.1
Steps to reproduce
Steps to reproduce the issue:
Expected behavior
I would expect the status to not be allowed to downgrade because that is the behavior of the JDBC implementation.
The text was updated successfully, but these errors were encountered: