Tuesday 25 May 2010

Using Hibernate 3.5.2 in JBoss 6.0.0-M3

DISCLAIMER: This works for me. I am not associated with JBoss/RedHat/Hibernate in any way, and this solution was arrived at via experimentation and an adequate working knowledge of Hibernate and JBoss. I'm happy to be corrected by anyone who knows better.

Envirnoment info:
Windows 7 x64 Ultimate
JDK 1.6.0_20 x64

In jboss-6.0.0.20100429-M3\common\lib, remove these jars:

hibernate-validator-legacy.jar
hibernate-validator.jar
hibernate-entitymanager.jar
hibernate-commons-annotations.jar
hibernate-jpa-2.0-api.jar
hibernate-annotations.jar
hibernate-core.jar


and replace with these:

geronimo-spec-jta-1.0.1B-rc4.jar
hibernate-validator-3.0.0.ga.jar
hibernate-jpa-2.0-api-1.0.0.Final.jar
hibernate-commons-annotations-3.2.0.Final.jar
hibernate-annotations-3.5.2-Final.jar
hibernate-core-3.5.2-Final.jar
hibernate-entitymanager-3.5.2-Final.jar


IIRC all these jars are from public Maven repositories. I don't recall having to add any manually to my master repo.

That's it. Like I say works for me. I intend to do the same thing on my Mac, which I assume will work the same. I'll post either way, should anyone be interested.