ClassCastException of persistence.xml
java.lang.ClassCastException: : org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration" occurred while attempting to determine the version of "zip:C:/JDeveloper/11.1.1.4.0/user_projects/domains/.../persistence.xml".
The problem maybe caused by the encoding of the persistence.xml.
Another possible reason is caused by the classloading of the xercesImpl.jar. Qwblogic has built-in xercesImpl.jar, your application should load the jar from parent classloader. However, usingorg.apache.xerces.* in weblogic-application.xml may cause classloading problem.
Solution:
Remove the prefer settings from weblogic-application.xml - not exactly work
or
exclude this jar from POM.xml. - work
The problem maybe caused by the encoding of the persistence.xml.
Another possible reason is caused by the classloading of the xercesImpl.jar. Qwblogic has built-in xercesImpl.jar, your application should load the jar from parent classloader. However, using
Solution:
Remove the prefer settings from weblogic-application.xml - not exactly work
or
exclude this jar from POM.xml. - work
留言
張貼留言