For anyone who finds this in future, this did the trick for me:
from(REQUEST_QUEUE_ENDPOINT)
.split(body(), new AggregationStrategy() {
public Exchange aggregate(Exchange oldExchange,
Exchange newExchange) {
if (oldExchange == null && newExchange
!= null) {
// Create list and add object
to it. Set list as body to new exchange
return newExchange;
} else {
// Add object from new exchange
to list on old exchange
return oldExchange;
}
}
})
.parallelProcessing()
// Procsesing goes here
.end()
.to(RESPONSE_QUEUE_ENDPOINT)
;
--
View this message in context:
http://camel.465427.n5.nabble.com/Splitting-processing-and-aggregating-a-list-tp5716013p5716076.html
Sent from the Camel - Users mailing list archive at Nabble.com.