遇到的jar包冲突的问题

Caused by: org.apache.maven.plugin.PluginExecutionException: Execution default-cli of goal org.mortbay.jetty:jetty-maven-plugin:8.1.11.v20130520:run failed: An API incompatibility was encountered while executing org.mortbay.jetty:jetty-maven-plugin:8.1.11.v20130520:run: java.lang.NoSuchMethodError: org.springframework.web.context.ConfigurableWebApplicationContext.getEnvironment()Lorg/springframework/web/context/ConfigurableWebEnvironment;

Caused by: org.apache.maven.plugin.PluginExecutionException: Execution default-cli of goal org.mortbay.jetty:jetty-maven-plugin:8.1.11.v20130520:run failed: An API incompatibility was encountered while executing org.mortbay.jetty:jetty-maven-plugin:8.1.11.v20130520:run: java.lang.NoSuchMethodError: org.springframework.web.context.ConfigurableWebApplicationContext.getEnvironment()Lorg/springframework/web/context/ConfigurableWebEnvironment;

这个是spring-web的jar包有冲突的原因,也就是说有的是使用的的3.2.0.RELEASE版本的,有的又是使用的4.2.0RELEASE,在pom.xml中添加spring-web的依赖统一一个版本。

java.lang.IllegalStateException:Detected both log4j-over-slf4j.jar AND slf4j-log4j12.jar on the class path, preempting StackOverflowError. See also http://www.slf4j.org/codes.html#log4jDelegationLoop for more details.和Caused by:
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.validation.beanvalidation.LocalValidatorFactoryBean#0': Invocation of init method failed; nested exception is java.lang.ExceptionInInitializerError

这个是日志jar包的冲突 :http://www.slf4j.org/codes.html#log4jDelegationLoop ,也是在pom.xml中对依赖进行相关修改

 

你可能感兴趣的:(遇到的jar包冲突的问题)