spring-projects / spring-batch-extensions

Spring Batch Extensions

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add support for resetting the currentSheet index to 0 upon doClose()

codelirium opened this issue · comments

Hello mdeinum,

Have a look @ #14

I think there is one more state variable that needs resetting plus I updated the unit tests.

Kindest regards,
Stavros Lekkas (@codelirium)

Hello @mminella, would that be possible to review and merge #14 ?

Why is doing this via a new instance using step scope not good enough? I ask since that's the way just about every other reader works...

I might sound weird to you but:

  1. I thought reusing the same reader adds up to flexibility.
  2. I did not want to create a separate reader bean tight to every additional pass I want to make to the excel file - in cases where more than one additional passes are required.

Do you have an example of where this approach is preferred than the step one I'm proposing?

I am afraid I do not. I just felt reusing the reader in the product I rolled out last month.

Fixed in #65.