-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Description
Bug description
I have a spring batch job with eg : 4 steps, the second steps fails and the flow is such that I need to update details so it goes on to the 3rd and 4th steps marks them as complete.
In the end of the job I update the job execution with status and exit status as failed and restart the job.
Step execution :
- Status - completed , exitstatus - completed
- Status - failed , exitstatus - failed
- Status - completed , exitstatus - completed
- Status - completed , exitstatus - completed
Job execution status failed and exit status failed
On restart non of the steps are executed again and the job ends successfully.
I want to restart the job from the failed step.
Now if I try to fail the last 3 steps
Step execution :
- Status - completed , exitstatus - completed
- Status - failed , exitstatus - failed
- Status - failed , exitstatus - failed
- Status - failed , exitstatus - failed
Job execution status failed and exit status failed
Here only the step 4 is executed on the restart, it's taking only the last failed step.
Environment
Please provide as many details as possible: Spring batch version - 5.1.2
Java version 17
Steps to reproduce
Given above
Expected behavior
How can I make the job restart from the second step which is the actual failed step