maven - Configure pom.xml for hibernate 3.6 -
i've tried configure pom.xml
file spring 3
, hibernate 3.6
application. relevant part of pom.xml
looks this:
<dependency> <groupid>mysql</groupid> <artifactid>mysql-connector-java</artifactid> <version>5.1.9</version> </dependency> <dependency> <groupid>org.hibernate</groupid> <artifactid>hibernate-core</artifactid> <version>3.6.3.final</version> </dependency> <dependency> <groupid>org.javassist</groupid> <artifactid>javassist</artifactid> <version>3.17.1-ga</version> </dependency> <dependency> <groupid>asm</groupid> <artifactid>asm-all</artifactid> <version>2.2</version> </dependency> <dependency> <groupid>antlr</groupid> <artifactid>antlr</artifactid> <version>2.7.7</version> </dependency>
nevertheless, if don't include javassist.jar
library directly buildpath external jar
, keep getting java.lang.classnotfoundexception
. there wrong in pom.xml
, due doesn't download dependency when building project?
try hibernate-entitymanager
instead of hibernate-core
.
<groupid>org.hibernate</groupid> <artifactid>hibernate-entitymanager</artifactid> <version>3.6.3.final</version> </dependency>
this include necessary dependencies transitively. check maven dependency hierarchy after make change.
btw lastest available version of hibernate in maven central 4.1.18
Comments
Post a Comment