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: If condition is met then we can continue the process ?
Date Tue, 19 May 2009 08:35:20 GMT
On Tue, May 19, 2009 at 10:11 AM, Charles Moulliard
<cmoulliard@gmail.com> wrote:
> Hi,
>
> I'm faced to the following problem that I want to solve without creating
> something too much complex :
>
> A collection of orders contained in a message is first splitted. Each
> individual order based on its type is routed and processed separately. The
> next step consists in to check if all the orders (coming from my collection
> A) have been processed. If this is the case and if they have their status
> equal to "Validated", then we can place the orders in a queue.
>
> I have checked the aggregator but it will recreate a new message containing
> all the orders and I don't want to do that.
>
> Is it possible to do what I describe in one transactional route ?

The splitter has build in aggregator that aggregates all the messages
it splits.

Roughly like

from -> transacted -> split (aggregator strategy) -> whatever route
each splitted message should do -> end (important to mark end of split
route )
-> to (*)

Ad *)
He we continue *AFTER* the split that have aggregated all the split
responses into a single message. This allows you to know if all order
was validated or not.

See the section - Split aggregate request/reply sample
On the splitter EIP page


>
> Regards,
>
> Charles Moulliard
> Senior Enterprise Architect
> Apache Camel Committer
>
> *****************************
> blog : http://cmoulliard.blogspot.com
>



-- 
Claus Ibsen
Apache Camel Committer

Open Source Integration: http://fusesource.com
Blog: http://davsclaus.blogspot.com/
Twitter: http://twitter.com/davsclaus

Mime
View raw message