-
Feb 6th, 2013, 11:08 AM
#1
Remote Chunking scope="step" dependencies on remote slaves
Currently we are trying to implement Remote Chunking and the processor/writer that is implemented to run on slave nodes has scope="step" dependency. This is causing the exception as the following. I'am wondering if any one has any suggestion to how to resolve this.
Exception :
org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'scopedTarget.updatePositionSchedule': 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
at org.springframework.beans.factory.support.Abstract BeanFactory.doGetBean(AbstractBeanFactory.java:339 )
at org.springframework.beans.factory.support.Abstract BeanFactory.getBean(AbstractBeanFactory.java:190)
Related slave node configuration.
<bean id="slaveChunkHandler" class="org.springframework.batch.integration.chunk .ChunkProcessorChunkHandler">
<property name="chunkProcessor" >
<bean class="org.springframework.batch.core.step.item.Si mpleChunkProcessor">
<property name="itemWriter" ref="PositionItemWriter"/>
<property name="itemProcessor">
<bean class="org.springframework.batch.item.support.Pass ThroughItemProcessor"/>
</property>
</bean>
</property>
</bean>
<bean id="PositionItemWriter"
class="org.springframework.batch.item.support.Comp ositeItemWriter">
<property name="delegates">
<list>
<ref bean="updatePositionSchedule"/>
</list>
</property>
</bean>
<bean id="updatePositionSchedule" scope="step"
class="com.xyz.batch.writer.PositionScheduleItemWr iter">
<property name="calcRequest" value="#{jobExecutionContext['calcRequest']}"/>
</bean>
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules