You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Bala <vb...@yahoo.co.in> on 2012/11/30 06:36:50 UTC
Camel multicast configuration file
Hi Team,
I am trying to configure camel multicasting in my project. The requirement
is to hit multiple services in parallel and consume the response. When I
tried, am getting the response in body of the second service alone. Am not
able to get the response of the first service. Please help me on this.
I have the configuration file as below.
<route>
<from uri="direct:signIn" />
<log message="****************Sign ON Request Fired************" />
<multicast parallelProcessing="true">
<pipeline>
<bean ref="signOnRequestHandler" />
<to uri="cxfrs://bean://signOnRsClient"/>
</pipeline>
<pipeline>
<bean ref="signOnRequestHandler1" />
<to uri="cxfrs://bean://signOnRsClient1"/>
</pipeline>
</multicast>
<unmarshal ref="jack"/>
<bean ref="signOnResponseHandler" />
</route>
Thanks, Bala
--
View this message in context: http://camel.465427.n5.nabble.com/Camel-multicast-configuration-file-tp5723427.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Camel multicast configuration file
Posted by Claus Ibsen <cl...@gmail.com>.
Hi
See the eip docs
http://camel.apache.org/multicast.html
And read about the aggregation strategy.
On Fri, Nov 30, 2012 at 6:36 AM, Bala <vb...@yahoo.co.in> wrote:
> Hi Team,
>
> I am trying to configure camel multicasting in my project. The requirement
> is to hit multiple services in parallel and consume the response. When I
> tried, am getting the response in body of the second service alone. Am not
> able to get the response of the first service. Please help me on this.
>
> I have the configuration file as below.
>
> <route>
> <from uri="direct:signIn" />
> <log message="****************Sign ON Request Fired************" />
> <multicast parallelProcessing="true">
> <pipeline>
> <bean ref="signOnRequestHandler" />
> <to uri="cxfrs://bean://signOnRsClient"/>
> </pipeline>
> <pipeline>
> <bean ref="signOnRequestHandler1" />
> <to uri="cxfrs://bean://signOnRsClient1"/>
> </pipeline>
> </multicast>
> <unmarshal ref="jack"/>
> <bean ref="signOnResponseHandler" />
> </route>
>
> Thanks, Bala
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Camel-multicast-configuration-file-tp5723427.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
--
Claus Ibsen
-----------------
Red Hat, Inc.
FuseSource is now part of Red Hat
Email: cibsen@redhat.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
Re: Camel multicast configuration file
Posted by Henryk Konsek <he...@gmail.com>.
> Thanks for the response. But I need to do the configuration in XML file
Ops, I missed your e-mail :) Do you still need it or figured it out? :)
--
Henryk Konsek
http://henryk-konsek.blogspot.com
Re: Camel multicast configuration file
Posted by Bala <vb...@yahoo.co.in>.
Thanks for the response. But I need to do the configuration in XML file
Sent from Yahoo! Mail on Android
--
View this message in context: http://camel.465427.n5.nabble.com/Camel-multicast-configuration-file-tp5723427p5723517.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Camel multicast configuration file
Posted by Henryk Konsek <he...@gmail.com>.
Hi Bala,
> I am trying to configure camel multicasting in my project. The requirement
> is to hit multiple services in parallel and consume the response.
As Claus suggested you forgot to aggregate the requests.
And here's how can you aggregate responses from multiple services:
from("direct:serviceAggregator")
.multicast(new GroupedExchangeAggregationStrategy()).parallelProcessing()
.enrich("http://servicea.com").enrich("http://serviceb.com")
.end();
Laters.
--
Henryk Konsek
http://henryk-konsek.blogspot.com