Hello, I am pretty new to Camel (but an old Mule-hand), so I hope anyone can
help me on this.
I require a route that does the following :
*Consume messages from Active MQ
*Aggregate these messages according to a strategy.
*Send these aggregates to a component for further processing.
Now, I require as much as this as possible to happen in parallell. That is :
message consumption from the queue, aggregation and further processing. The
aggregator is very flexible, so ordering of messages is not an issue here, it
aggregates whatever it gets.
I have read something about an aggregator being a singleton, so that also
confuses me a bit.
Does the route below sound reasonable ? I am a little confused about the
interplay with concurrentConsumers and parallellProcessing, but I guess the
first makes sure that there are a number of threads consuming the messages, and
the second controls the aggregation ? Do I need one or two paralleProcessing()
calls in the route below ? My current interpretation is that the first controls
the aggregation and the second the "furtherProcessing", is that correct ?
from("jms:queue:jalla?concurrentConsumers=12&maxConcurrentConsumers=50").aggregate(constant(true),new
ArrayListAggregationStrategy()).completionSize(3).parallelProcessing()
.to("furtherProcessing").parallelProcessing();