title: Best strategy for processing large CSV files in Apache Camel
body: <p>I'd like to develop a route that polls a directory containing CSV files, and for every file it unmarshals each row using Bindy and queues it in activemq. </p>
  
  <p>The problem is files can be pretty large (a million rows) so I'd prefer to queue one row at a time, but what I'm getting is all the rows in a java.util.ArrayList at the end of Bindy which causes memory problems.</p>
  
  <p>So far I have a little test and unmarshaling is working so Bindy configuration using annotations is ok.</p>
  
  <p>Here is the route:</p>
  
  <pre><code>from("file://data/inbox?noop=true&amp;maxMessagesPerPoll=1&amp;delay=5000")
    .unmarshal()
    .bindy(BindyType.Csv, "com.ess.myapp.core")           
    .to("jms:rawTraffic");
  </code></pre>
  
  <p>Environment is: Eclipse Indigo, Maven 3.0.3, Camel 2.8.0</p>
  
  <p>Thank you</p>