I've been using docx4j (v 3.2.1, on Windows 7 Pro 64 bit and MS-Word 2013, 64-bit Java 8), off and on, for a couple of years now and really appreciate this product. I am currently creating very large documents (~ 15k pages) which have bookmarks all over the place to help people navigate around such a huge tome. When I FIRST load the docx4j created docx file, it takes a LONG time to load (like 30-60 minutes on a 4gb machine with 4 cores). I assume that MS-Word is probably optimizing the document some how because future loads of the .docx file are much faster. I'm guessing that the way I am creating the docx file must be inefficient. So, my general questions are:
1. Are there some general design patterns for creating efficient documents you can recommend
2. Are there any anti-patterns I should stay away from in general and for large documents specifically.
3. Should I step up to v 3.2.2 (or higher)(I read the release notes and did not see anything about performance increases)
4. Throw more cores or RAM at the problem?
5. Would upgrading to a newer version of Word help?
Thanks again for these great libraries!
Bart