SPRING MVC 3.2.2 + SPRING SECURITY 3.1.3 INCOMPATIBILITY java.lang.IncompatibleClassChangeError -
have changed version of spring security in application 3.2.0.m1 3.1.3 have error when tomcat launches application. first row of exception stack following:
2013-04-25 11:33:12,893 [localhost-startstop-1] error org.springframework.web.context.contextloader - org.springframework.web.context.contextloader - context initialization failed org.springframework.beans.factory.beandefinitionstoreexception: failed read candidate component class: file [c:\users\daniele\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\ice-cream-webapp\web-inf\classes\com\myprj\app\web\controller\frontpagescontroller.class]; nested exception java.lang.incompatibleclasschangeerror: class org.springframework.core.type.classreading.classmetadatareadingvisitor has interface org.springframework.asm.classvisitor super class
and pom.xml is:
<project xmlns="http://maven.apache.org/pom/4.0.0" xmlns:xsi="http://www.w3.org/2001/xmlschema-instance" xsi:schemalocation="http://maven.apache.org/pom/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelversion>4.0.0</modelversion> <groupid>com.company</groupid> <artifactid>myprj-webapp</artifactid> <packaging>war</packaging> <version>0.0.1-snapshot</version> <name>myprj-webapp</name> <url>http://www.company.com</url> <properties> <org.springframework.version>3.2.2.release</org.springframework.version> <org.springframework.test.version>3.2.2.release</org.springframework.test.version> <org.springframework.security.version>3.1.3.release</org.springframework.security.version> <org.springframework.security.oauth.version>1.0.2.release</org.springframework.security.oauth.version> <project.build.sourceencoding>utf-8</project.build.sourceencoding> </properties> <dependencies> <dependency> <groupid>org.springframework</groupid> <artifactid>spring-webmvc</artifactid> <version>${org.springframework.version}</version> </dependency> <dependency> <groupid>org.springframework.security</groupid> <artifactid>spring-security-taglibs</artifactid> <version>${org.springframework.security.version}</version> </dependency> <dependency> <groupid>jstl</groupid> <artifactid>jstl</artifactid> <version>1.2</version> </dependency> <dependency> <groupid>org.springframework.security.oauth</groupid> <artifactid>spring-security-oauth2</artifactid> <version>${org.springframework.security.oauth.version}</version> </dependency> <dependency> <groupid>log4j</groupid> <artifactid>log4j</artifactid> <version>1.2.17</version> </dependency> <dependency> <groupid>net.sourceforge.findbugs</groupid> <artifactid>annotations</artifactid> <version>1.3.2</version> </dependency> <dependency> <groupid>org.apache.tomcat</groupid> <artifactid>tomcat-servlet-api</artifactid> <version>7.0.34</version> <scope>provided</scope> </dependency> <!-- test dependencies --> <dependency> <groupid>org.springframework</groupid> <artifactid>spring-test</artifactid> <version>${org.springframework.test.version}</version> <scope>test</scope> </dependency> <dependency> <groupid>junit</groupid> <artifactid>junit</artifactid> <version>4.10</version> <scope>test</scope> </dependency> </dependencies> <repositories> <repository> <id>org.springframework.maven.milestone</id> <name>spring maven milestone repository</name> <url>http://maven.springframework.org/milestone</url> <snapshots> <enabled>true</enabled> </snapshots> </repository> </repositories> <build> <finalname>myprj-webapp</finalname> <resources> <resource> <directory>src/main/resources</directory> <filtering>true</filtering> </resource> </resources> <plugins> <plugin> <groupid>org.apache.maven.plugins</groupid> <artifactid>maven-compiler-plugin</artifactid> <version>2.3.2</version> <configuration> <source>1.7</source> <target>1.7</target> </configuration> </plugin> </plugins> </build>
it 1 day working on that, have still no idea dependecies create conflict.
idea?
use mvn dependency:tree find dependencies getting.
looks have spring-asm jar
in causing issue post 3.2 of merged spring-core
.