我在嘗試將我的Web應用程序部署到GlassFish 3.1.2時遇到了問題。看起來有JAXB庫衝突:我的應用程序使用v.1 JAXB實現,而AFAIK和GlassFish 3.1.2包含它自己的v2 JAXB實現。這可能會導致在部署過程中失敗嗎?如何在這種情況下采取行動?GlassFish的JAXB實現
異常消息:
Caused by: rpt.engine.util.EngineException: javax.xml.bind.JAXBException: Provider com.sun.xml.bind.ContextFactory_1_0_1 could not be instantiated: javax.xml.bind.JAXBException - with linked exception: [java.lang.NoSuchFieldError: theInstance]
- with linked exception: [javax.xml.bind.JAXBException - with linked exception: [java.lang.NoSuchFieldError: theInstance]] at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:160) at javax.xml.bind.ContextFinder.find(ContextFinder.java:308) at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:446) at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:409) at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:313)
感謝答覆。去嘗試。 –