I try to generate a huge xml with Camel from java objects (from a database).
Is there a way to do this with a camel route, loading data from database to objects, marshalling them to xml and streaming to a file, in order to minimize memory usage ?
I found many examples to split a huge xml file and insert data to database, but not the contrary.
The xml file to generate is similar to this :
<root>
<libraryHeader>
<field></field>
<field></field>
...
</libraryHeader>
<books>
<book>... <field></field> ...</book>
<book>... <field></field> ...</book>
...
</books>
</root>
Thank you very much for your advices