-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Fault tolerant steps may ignore chunks silently #3828
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Thank you for raising this issue. I believe this is a duplicate of #1189. Do you confirm that? |
Hello @benas I can confirm that it is the same issue. Is it something that you consider changing or will it be kept as is ? |
Thank you for your confirmation. I will close this as a duplicate of #1189.
Both this issue and #1189 are reported against Spring Batch v3, which is not maintained anymore. If this is validated as a bug with a minimal complete example against the current v4.3.1, we will take a look. |
Hello @fmbenhassine, i am also having this problem with 4.3.8. |
Bug description
During the execution of a fault tolerant Step, when a chunk executes successfully, it is tagged as “Completed”, and then, we try to commit the transaction.
In the case where the transaction commit fails with an exception that is not considered as Non-retryable or Fatal (by FaultTolerantStepBuider) like a RuntimeException, the exception handler logs the error in debug (SimpleRetryExceptionHandler#handleException), and we do not put back the chunk in the queue for retry (since tagged Completed) and consequently we skip the chunk silently while having it tagged as “Completed”.
We end up in this case with a "Completed" job with "Completed" chunks and no error stacks.
Environment
Spring Batch version: 3.0.10.RELEASE
Java version: 11
database: postgresql
ORM: hibernate
Steps to reproduce
Expected behavior
Retry the chunk, and if the error persist throw an error and mark the job as failed.
The text was updated successfully, but these errors were encountered: