Probably the simplest solution is to write a small bean or processor, reading the in stream first calculating the target based on the first line then building up the 1000 line packets and sending them using the request or send methods of ProducerTemplate. This is most likely simpler and cleaner than using the EIPs mentioned in my earlier suggestions.
-- View this message in context: http://camel.465427.n5.nabble.com/processing-data-based-on-the-metadata-in-the-file-using-apache-camel-tp5752593p5752956.html Sent from the Camel - Users mailing list archive at Nabble.com.