I am writing spring batch having dynamic size of chunk. I am using skip policy which skips item if any kind of exception occurs.
Now the when exception occurs in writer it does following,
when the item writer throws a skippable exception. Because the framework doesn’t know which item threw the exception, it reprocesses single item at a time and pass single item to writer (except error item)
What I want is if any kind of exception occurs in writer it will pass all items (except error one) as a list to writer again and NOT one by one. I am creating excel file in writer there I need all item in chunk at same time and not one by one.
Is there any way to achieve this in spring batch?
Thank you !!