I am using Spring Integration+Spring Dm server 2.0 +Spring Batch
In one of my spring batch jobs writer i am trying - to use a gatewayProxyFactory bean and putting a message into a pub sub channel.
This pub sub channel is exposed as a osgi service. There are other bundle which subscribe to this pub sub channel and have respective service activators.
Now when there are no subscribers , what the expected behavior ? Will a subscriberNotAvalibale exception be thrown , or message on teh channel will simply be discarded.
I tried this sample with spring batch+spring dm 2.0+spring integration 1.3
But i get teh following exception when there are no subscribers
Code:[2010-02-03 16:27:10.046] edulerFactoryBean#0_Worker-9 org.springframework.batch.core.step.AbstractStep Encountered an error executing the step org.springframework.integration.message.MessageDeliveryException: failed to send Message to channel at org.springframework.integration.gateway.AbstractMessagingGateway.send(AbstractMessagingGateway.java:129) at org.springframework.integration.gateway.GatewayProxyFactoryBean.invokeGatewayMethod(GatewayProxyFactoryBean.java:206) at org.springframework.integration.gateway.GatewayProxyFactoryBean.invoke(GatewayProxyFactoryBean.java:172) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202) at $Proxy134.write(Unknown Source) at com.pg.batch.SampleWriter.write(SampleWriter.java:18) at org.springframework.batch.core.step.item.SimpleChunkProcessor.writeItems(SimpleChunkProcessor.java:156) at org.springframework.batch.core.step.item.SimpleChunkProcessor.doWrite(SimpleChunkProcessor.java:137) at org.springframework.batch.core.step.item.SimpleChunkProcessor.write(SimpleChunkProcessor.java:252) at org.springframework.batch.core.step.item.SimpleChunkProcessor.process(SimpleChunkProcessor.java:178) a


Reply With Quote
