Monday, November 04, 2013

multiple XML APIs in project

If you have below exceptions in tests or runtime, it's cause by multiple XML APIs / implementations in your project. How to find and exclude them is beyond this post.

ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[resteasy-servlet]] (http- Servlet.service() for servlet resteasy-servlet threw exception
java.lang.LinkageError: loader constraint violation: when resolving field "DATETIME" the class loader (instance of org/jboss/classloader/spi/base/BaseClassLoader) of the referring class, javax/xml/datatype/DatatypeConstants, and the class loader (instance of ) for the field's resolved type, javax/xml/namespace/QName, have different Class objects for that type
at com.sun.xml.bind.v2.model.impl.RuntimeBuiltinLeafInfoImpl.(

java.lang.IllegalStateException: Failed to load ApplicationContext
at com.sun.xml.bind.v2.runtime.ClassBeanInfoImpl.checkOverrideProperties(
at com.sun.xml.bind.v2.runtime.ClassBeanInfoImpl.(
at com.sun.xml.bind.v2.runtime.JAXBContextImpl.getOrCreate(
at com.sun.xml.bind.v2.runtime.JAXBContextImpl.getOrCreate(

No comments:

Post a Comment