The reader looks like this:
<bean id="cvsFileItemReader" class="org.springframework.batch.item.file.FlatFileItemReader" scope="step">
<property name="resource" value="classpath:cvs/input/report.csv" />
<property name="lineMapper">
<bean class="org.springframework.batch.item.file.mapping.DefaultLineMapper">
<property name="lineTokenizer">
<bean
class="org.springframework.batch.item.file.transform.DelimitedLineTokenizer">
<property name="names" value="id,impressions" />
</bean>
</property>
<property name="fieldSetMapper">
<bean
class="org.springframework.batch.item.file.mapping.BeanWrapperFieldSetMapper">
<property name="prototypeBeanName" value="report" />
</bean>
</property>
</bean>
</property>
</bean>
What I want to achieve is that if the read / task problem fails while reading the CSV file, then the next scheduled task should start from a line that it could not handle in the last execution. I can track the rows processed by the counter in the CustomProcessor process () function.
But any idea how to read the csv file from the last default state?
I want to start / restart a failed job manually. Should I implement SkipPolicy as described here http://thisisurl.com/spring-batch-skip-and-retry ?
(CSV , CSV)