[
http://opensource.atlassian.com/projects/hibernate/browse/HHH-5896?page=c...
]
Javed Mandary commented on HHH-5896:
------------------------------------
Having looked again at the issue it would seem that in some instances maven3 hides
transitive dependencies it is bringing into your build .. to be sure where unwanted
dependencies are comming from add the -X flag e.g mvn clean install -X .
I've found that hibernate-3.2.5.ga.jar was being added because I had a dependency with
atomikos which was pulling out this jar transitively. Excluding the hibernate-3.2.5.ga jar
from atomikos solved the problem:
<dependency>
<groupId>com.atomikos</groupId>
<artifactId>transactions-jta</artifactId>
<version>3.6.4</version>
<exclusions>
<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
</exclusion>
<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging-api</artifactId>
</exclusion>
<exclusion>
<groupId>org.hibernate</groupId>
<artifactId>hibernate</artifactId>
</exclusion>
</exclusions>
</dependency>
hibernate-entitymanager jar issue with Maven 3
-----------------------------------------------
Key: HHH-5896
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-5896
Project: Hibernate Core
Issue Type: Bug
Affects Versions: 3.5.1, 3.6.0, 3.6.1
Reporter: Javed Mandary
Hi,
I would seem that if you include the hibernate-entitymanager (3.6.1) dependency within
your maven build and your using Maven 3 , this pulls the hibernate-3.2.5.ga.jar within
your classpath somehow.
Eventually what happens is that if you try to run your application within say tomcat and
that bundles the hibernate-entitymanager jar as well as the hibernate-3.2.5.ga.jar you get
the following exception:
Invocation of init method failed; nested exception is
java.lang.IncompatibleClassChangeError: Implementing class
at
org.springframework.context.annotation.CommonAnnotationBeanPostProcessor.postProcessPropertyValues(CommonAnnotationBeanPostProcessor.java:300)
Solution which I've found is to move down to maven 2 or to expliclty or manually
remove the hibernate-3.2.5.ga.jar from your build.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira