You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Jothi <co...@gmail.com> on 2013/06/26 17:57:12 UTC

Aggregator to be pulled from the bean definition

Guys,

I have the following route:

from("direct:aggregate").aggregate(header(CORRELATION_HEADER_KEY), new
MyAggregationStrategy()).completionTimeout(3000).to(DIRECT_FINISH_AGGREGATE).routeId("myAggregator");

I want this new MyAggregationStrategy() to be injected via a bean definition
from my blueprint.xml. Is there a way to do this? 





--
View this message in context: http://camel.465427.n5.nabble.com/Aggregator-to-be-pulled-from-the-bean-definition-tp5734826.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Aggregator to be pulled from the bean definition

Posted by Jothi <co...@gmail.com>.
I figured that out. I had to browse through the API reference that took me a
while!

Anyways, thanks for the response!

Regards,
Jothi



--
View this message in context: http://camel.465427.n5.nabble.com/Aggregator-to-be-pulled-from-the-bean-definition-tp5734826p5734884.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Aggregator to be pulled from the bean definition

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

Yeah you can use aggregationStrategyRef to refer to the bean id.

aggregate(header(CORRELATION_HEADER_KEY)).aggregationStrategyRef("xxxx")...

On Wed, Jun 26, 2013 at 5:57 PM, Jothi <co...@gmail.com> wrote:
> Guys,
>
> I have the following route:
>
> from("direct:aggregate").aggregate(header(CORRELATION_HEADER_KEY), new
> MyAggregationStrategy()).completionTimeout(3000).to(DIRECT_FINISH_AGGREGATE).routeId("myAggregator");
>
> I want this new MyAggregationStrategy() to be injected via a bean definition
> from my blueprint.xml. Is there a way to do this?
>
>
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Aggregator-to-be-pulled-from-the-bean-definition-tp5734826.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
www.camelone.org: The open source integration conference.

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