You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by cmoulliard <cm...@gmail.com> on 2008/03/18 13:15:52 UTC
Extend File Component property (Nbe lines/message)
Hi,
I would like to propose to extend the file component of camel by adding new
properties :
- Nber lines/message
in order to provide when the file is formatted as a CSV file the number of
lines to put in a message. This strategy can improve performance when the
file contain thousands of records and we want to parralelize the work.
- CSV separator
- CSV end line delimitor
Regards,
Charles
--
View this message in context: http://www.nabble.com/Extend-File-Component-property-%28Nbe-lines-message%29-tp16119613s22882p16119613.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Extend File Component property (Nbe lines/message)
Posted by Roman Kalukiewicz <ro...@gmail.com>.
2008/3/18, cmoulliard <cm...@gmail.com>:
>
> Hi,
>
> I would like to propose to extend the file component of camel by adding new
> properties :
>
> - Nber lines/message
>
> in order to provide when the file is formatted as a CSV file the number of
> lines to put in a message. This strategy can improve performance when the
> file contain thousands of records and we want to parralelize the work.
>
> - CSV separator
> - CSV end line delimitor
I don't know if there is anyone still interested in the answer, but
let me propose using parallel splitter() functionality here.
we can just
from("file:file.csv").splitter(body(String).tokenize("\n"),
true).unmarshal().csv().to("direct:processing");
where 'true' in splitter() marks, that it should be processed in
parallel. Should work.
Roman