Usage example for BatchResourceFactoryBean
Hi,
I am very interested in this project. I am watching results for a while. Now , I am trying to use spring-batch for new project in my company.
I have successfuly install it, and run samples.
But, I can not make BatchResourceFactoryBean to work. Can you provide configuration for fixedLengthImportJob?
I tried with:
<bean id="fileLocator"
class="org.springframework.batch.execution.resourc e.BatchResourceFactoryBean"
scope="step">
<property name="rootDirectory" value="file://c/gsm2/data/inct" />
<property name="filePattern" value="%BATCH_ROOT%/%JOB_NAME%" />
<aop:scoped-proxy />
</bean>
The error I receive is:
Error creating bean with name 'scopedTarget.fileLocator': Scope 'step' is not active for the current thread; consider defining a scoped proxy for this bean if you intend to refer to it from a singleton; nested exception is java.lang.IllegalStateException: No context holder available for step scope
Thanks in advance