You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by LavanyaKC <ck...@progress.com> on 2008/10/27 12:02:28 UTC

How do we set batchOutSize for an aggregator?

I am using aggregator pattern and want to set the batchOutSize property
(http://activemq.apache.org/camel/aggregator.html). I do not see any method
exposed in AggregatorType for setting this value. How to do this?

Thanks for any help.
-- 
View this message in context: http://www.nabble.com/How-do-we-set-batchOutSize-for-an-aggregator--tp20185550s22882p20185550.html
Sent from the Camel - Users mailing list archive at Nabble.com.


RE: How do we set batchOutSize for an aggregator?

Posted by Claus Ibsen <ci...@silverbullet.dk>.
Hi

The examples should have been grouped/explained better I guess.

The first line (commented out) is because of a bug in Camel (CAMEL-393).
See known issue in 1.5: http://activemq.apache.org/camel/camel-150-release.html

So you have to divide that into two routes (2nd + 3rd) line. And they are "linked" using the "direct:temp" queue.


//from("seda:header").setHeader("visited", constant(true)).aggregator(header("cheese")).to("mock:result");
from("seda:header").setHeader("visited", constant(true)).to("direct:temp");

from("direct:temp").aggregator(header("cheese")).to("mock:result");


I will improve this code, to explain it better.
{snippet:id=ex|lang=java|url=activemq/camel/trunk/camel-core/src/test/java/org/apache/camel/processor/AggregatorTest.java}


Med venlig hilsen
 
Claus Ibsen
......................................
Silverbullet
Skovsgårdsvænget 21
8362 Hørning
Tlf. +45 2962 7576
Web: www.silverbullet.dk

-----Original Message-----
From: LavanyaKC [mailto:ckonda@progress.com] 
Sent: 27. oktober 2008 12:47
To: camel-user@activemq.apache.org
Subject: RE: How do we set batchOutSize for an aggregator?


Thanks for a quick response Claus.

I have one more question in Aggregator documentation 
In the examples of aggregator
(http://activemq.apache.org/camel/aggregator.html)
the second example in "Using the Fluent Builders" section

from("seda:header").setHeader("visited", constant(true)).to("direct:temp")
is listed.

How is this an aggregator? I guess, this does not combine the messages from
seda:header to a single message.

Thanks
Lavanya.

Claus Ibsen wrote:
> 
> Hi
> 
> This setting is new in Camel 1.5. I will update the documentation.
> 
> You can try the 1.5-SNAPSHOT at:
> http://activemq.apache.org/camel/download.html
> 
> 
> Med venlig hilsen
>  
> Claus Ibsen
> ......................................
> Silverbullet
> Skovsgårdsvænget 21
> 8362 Hørning
> Tlf. +45 2962 7576
> Web: www.silverbullet.dk
> 
> -----Original Message-----
> From: LavanyaKC [mailto:ckonda@progress.com] 
> Sent: 27. oktober 2008 12:02
> To: camel-user@activemq.apache.org
> Subject: How do we set batchOutSize for an aggregator?
> 
> 
> I am using aggregator pattern and want to set the batchOutSize property
> (http://activemq.apache.org/camel/aggregator.html). I do not see any
> method
> exposed in AggregatorType for setting this value. How to do this?
> 
> Thanks for any help.
> -- 
> View this message in context:
> http://www.nabble.com/How-do-we-set-batchOutSize-for-an-aggregator--tp20185550s22882p20185550.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/How-do-we-set-batchOutSize-for-an-aggregator--tp20185550s22882p20186178.html
Sent from the Camel - Users mailing list archive at Nabble.com.


RE: How do we set batchOutSize for an aggregator?

Posted by LavanyaKC <ck...@progress.com>.
Thanks for a quick response Claus.

I have one more question in Aggregator documentation 
In the examples of aggregator
(http://activemq.apache.org/camel/aggregator.html)
the second example in "Using the Fluent Builders" section

from("seda:header").setHeader("visited", constant(true)).to("direct:temp")
is listed.

How is this an aggregator? I guess, this does not combine the messages from
seda:header to a single message.

Thanks
Lavanya.

Claus Ibsen wrote:
> 
> Hi
> 
> This setting is new in Camel 1.5. I will update the documentation.
> 
> You can try the 1.5-SNAPSHOT at:
> http://activemq.apache.org/camel/download.html
> 
> 
> Med venlig hilsen
>  
> Claus Ibsen
> ......................................
> Silverbullet
> Skovsgårdsvænget 21
> 8362 Hørning
> Tlf. +45 2962 7576
> Web: www.silverbullet.dk
> 
> -----Original Message-----
> From: LavanyaKC [mailto:ckonda@progress.com] 
> Sent: 27. oktober 2008 12:02
> To: camel-user@activemq.apache.org
> Subject: How do we set batchOutSize for an aggregator?
> 
> 
> I am using aggregator pattern and want to set the batchOutSize property
> (http://activemq.apache.org/camel/aggregator.html). I do not see any
> method
> exposed in AggregatorType for setting this value. How to do this?
> 
> Thanks for any help.
> -- 
> View this message in context:
> http://www.nabble.com/How-do-we-set-batchOutSize-for-an-aggregator--tp20185550s22882p20185550.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/How-do-we-set-batchOutSize-for-an-aggregator--tp20185550s22882p20186178.html
Sent from the Camel - Users mailing list archive at Nabble.com.


RE: How do we set batchOutSize for an aggregator?

Posted by Claus Ibsen <ci...@silverbullet.dk>.
Hi

This setting is new in Camel 1.5. I will update the documentation.

You can try the 1.5-SNAPSHOT at:
http://activemq.apache.org/camel/download.html


Med venlig hilsen
 
Claus Ibsen
......................................
Silverbullet
Skovsgårdsvænget 21
8362 Hørning
Tlf. +45 2962 7576
Web: www.silverbullet.dk

-----Original Message-----
From: LavanyaKC [mailto:ckonda@progress.com] 
Sent: 27. oktober 2008 12:02
To: camel-user@activemq.apache.org
Subject: How do we set batchOutSize for an aggregator?


I am using aggregator pattern and want to set the batchOutSize property
(http://activemq.apache.org/camel/aggregator.html). I do not see any method
exposed in AggregatorType for setting this value. How to do this?

Thanks for any help.
-- 
View this message in context: http://www.nabble.com/How-do-we-set-batchOutSize-for-an-aggregator--tp20185550s22882p20185550.html
Sent from the Camel - Users mailing list archive at Nabble.com.