webservice调用异常


Exception in thread "main" java.lang.LinkageError: JAXB 2.1 API jar is being loaded (from jar:file:/C:/Users/Administrator/.m2/repository/org/apache/openejb/javaee-api/5.0-1/javaee-api-5.0-1.jar!/javax/xml/bind/annotation/XmlSchema.class), but this RI (from jar:file:/C:/Users/Administrator/.m2/repository/com/sun/xml/bind/jaxb-impl/2.2.4-1/jaxb-impl-2.2.4-1.jar!/com/sun/xml/bind/v2/model/impl/ModelBuilder.class) requires JAXB 2.2 API jar.

意思:现在使用的是JAXB 2.1的API 与 apache/openejb/javaee-api/5.0-1/javaee-api-5.0-1.jar 冲突
版本冲突,将pom.xml里的



<dependency>
<groupId>org.apache.openejb</groupId>
<artifactId>javaee-api</artifactId>
<version>5.0-1</version>
<scope>provided</scope>
</dependency>

去掉 重新clean下 ,运行 OK

上一篇:
下一篇:

发表评论

邮箱地址不会被公开。 必填项已用*标注

昵称 *