leostiw
leostiw

Reputation: 1155

docx4j inside JBoss NoClassDefFoundError

I get following error when executing on jboss :

WordprocessingMLPackage template = WordprocessingMLPackage .load(new FileInputStream(new File(name)));

Error: java.lang.NoClassDefFoundError: Could not initialize class org.docx4j.jaxb.Context

I know there is already a question regarding this issue, but no answer was given and seems like the question was left behind.

Upvotes: 1

Views: 2847

Answers (1)

JasonPlutext
JasonPlutext

Reputation: 15863

Please see my new answer at Cannot use docx4j inside of JBoss 7

My test used same version of JBoss (7.1.1) but:

  • old Java (1.6.0_27)
  • newer docx4j (current nightly)

I don't think those differences should matter though.

With this config, it is safe to ignore the log message java.lang.ClassNotFoundException: com.sun.xml.internal.bind.marshaller.NamespacePrefixMapper

Upvotes: 1

Related Questions