camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject Re: Aggregate, completion, notifybuilder
Date Thu, 12 Jan 2017 09:26:02 GMT
If you have the Camel in Action book I suggest you read the chapter /
sections about the aggregator EIP as its one of the most complex EIPs
and its detailed explained in the book with the background information
you need to understand.

On Thu, Jan 12, 2017 at 10:18 AM, sa_james <sa_reminder@hotmail.com> wrote:
> Still riding the camel and I became confused with aggregate while doing some
> tests. Consider:
>
> /from("direct:start").aggregate(constant(true)).groupExchanges().completionSize(2)
>    .to("log:I-see-you")
>    .to("file:target").routeId("myroute")
>
> template.sendBody("direct:start","Exchange1")
> template.sendBody("direct:start","Exchange2")
> /
> Now My Question:
> *How do I test that the aggregated Exchange is complete?
> *
> I tried the followings and the first two behave differently from the last 2.
> /
> NotifyBuilder(context).*fromRoute("myroute")*.whenDone(1).create()
> NotifyBuilder(context).*fromRoute("myroute")*.whenCompleted(1).create()
>
> NotifyBuilder(context).*from("log:I-see-you")*.whenDone(1).create()
> NotifyBuilder(context).*from("log:I-see-you")*.whenCompleted(1).create()/
>
> *What does happen to the first 2 messages when they have been aggregated?*
>
> THanks.
>
> Camel is Awesome.
>
>
>
>
> -----
> Guile Newbie
> --
> View this message in context: http://camel.465427.n5.nabble.com/Aggregate-completion-notifybuilder-tp5792441.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2

Mime
View raw message