camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jason Coelho <>
Subject Splitting a large xml file
Date Sat, 17 Jul 2010 19:02:46 GMT
I just recently started using Apache Camel and am trying to persist a very
large xml file (about 1Gb). At the same, I would like to create jms messages
/ events for each entry in the xml file.

My current approach is to split the XML file using the splitter and then
unmarshalling each entry and saving it to the DB.

XStream xstream = new XStream(new StaxDriver());
XStreamDataFormat dataFormat = new XStreamDataFormat(xstream);

                .process(new SaveRovi()).to("log:loggingCategory");

Unfortunately, I get an exception when I try the above.

java.lang.ClassCastException: cannot be cast to

Any ideas / solutions ? How do I fix this ? Since the xml file is large, I
don't want to use a DOM parser


View raw message