Class WorkerConfiguration
- java.lang.Object
- org.springframework.batch.sample.remotechunking.WorkerConfiguration
@Configuration @EnableBatchProcessing @EnableBatchIntegration @EnableIntegration @PropertySource("classpath:remote-chunking.properties") public class WorkerConfiguration extends java.lang.Object
This configuration class is for the worker side of the remote chunking sample. It uses theRemoteChunkingWorkerBuilderto configure anIntegrationFlowin order to:- receive requests from the master
- process chunks with the configured item processor and writer
- send replies to the master
- Author:
- Mahmoud Ben Hassine
Constructor Summary
Constructors Constructor Description WorkerConfiguration()
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.activemq.ActiveMQConnectionFactoryconnectionFactory()org.springframework.integration.dsl.IntegrationFlowinboundFlow(org.apache.activemq.ActiveMQConnectionFactory connectionFactory)ItemProcessor<java.lang.Integer,java.lang.Integer>itemProcessor()ItemWriter<java.lang.Integer>itemWriter()org.springframework.integration.dsl.IntegrationFlowoutboundFlow(org.apache.activemq.ActiveMQConnectionFactory connectionFactory)org.springframework.integration.channel.DirectChannelreplies()org.springframework.integration.channel.DirectChannelrequests()org.springframework.integration.dsl.IntegrationFlowworkerIntegrationFlow()
Method Detail
connectionFactory
@Bean public org.apache.activemq.ActiveMQConnectionFactory connectionFactory()
requests
@Bean public org.springframework.integration.channel.DirectChannel requests()
inboundFlow
@Bean public org.springframework.integration.dsl.IntegrationFlow inboundFlow(org.apache.activemq.ActiveMQConnectionFactory connectionFactory)
replies
@Bean public org.springframework.integration.channel.DirectChannel replies()
outboundFlow
@Bean public org.springframework.integration.dsl.IntegrationFlow outboundFlow(org.apache.activemq.ActiveMQConnectionFactory connectionFactory)
itemProcessor
@Bean public ItemProcessor<java.lang.Integer,java.lang.Integer> itemProcessor()
itemWriter
@Bean public ItemWriter<java.lang.Integer> itemWriter()
workerIntegrationFlow
@Bean public org.springframework.integration.dsl.IntegrationFlow workerIntegrationFlow()