Not my experience. The JAXB context does take a while to initialise (owing to the complexity of the OpenXML schemas) - on my Windows machine about 5 sec - but that is a one-off operation per execution of docx4j. (ie do it once, process many docx)
- Code: Select all
28.09.2010 11:03:05 *INFO * Context: loading Context jc (Context.java, line 73)
28.09.2010 11:03:10 *INFO * Context: loaded com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl .. loading others .. (Context.java, line 78)
28.09.2010 11:03:10 *INFO * Context: .. others loaded .. (Context.java, line 91)
So, more info pls ... turn on logging for org.docx4j.jaxb.Context .. and tell us whether it is the loading of Context, or your document.
Are you experiencing your problem with one particular document, or all documents? If it is a particular document, you could post it here (rename to .zip). Does it contain a lot of images? There is an option for lazy loading of these, which might help.
What is the execution environment? Operating system, RAM, and CPU. How much memory are you allocating to the JVM (-xmx etc).