Hi I think your split size is actually 9999, try use the header from the split, CamelSplitSize.
Taariq On Tue, Nov 5, 2013 at 1:57 PM, Olaf <omgolafg...@gmail.com> wrote: > Hello, > > is there an easy way to count and sum all processed lines by an aggregator? > Suppose, my file has 9999 lines, the route split it into 100 lines chunks > and send them to a remote system. The goal is, to gather statistics of all > sent lines. In the example below, .log() would always print the aggregation > size (100 or less) and not the number of overall processed messages, which > should be 9999 > > @Override > public void configure() throws Exception { > from("file:input.csv") > > .unmarshal().csv().split(body()).streaming().parallelProcessing() > .bean("myProcessor", "doWork") > .aggregate(constant("id"), new > Aggregator()).completionSize(100).completionTimeout(1000) > .parallelProcessing() > .to("remote") > .log("Sent ${header.RecordsCounter} records to remote"); > } > > Thanks in advance! > > > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/count-of-processed-messages-when-using-aggregation-tp5742649.html > Sent from the Camel - Users mailing list archive at Nabble.com. >