• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Bear Bibeault
  • Devaka Cooray
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Knute Snortum
  • Junilu Lacar
  • paul wheaton
Saloon Keepers:
  • Ganesh Patekar
  • Frits Walraven
  • Tim Moores
  • Ron McLeod
  • Carey Brown
  • Stephan van Hulst
  • salvin francis
  • Tim Holloway

Application throwing error while using org.hibernate.annotations.Entity  RSS feed

Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
if I map entities with org.hibernate.annotations.Entity, my application breaks with following error during run time . But it works fine if I use javax.persistence.Entity to map entities

Error -

Currently I am using hibernate-core-3.6.9.Final and hibernate-annotations-3.5.6-Final jar in my application.

Considering that in hibernate 3.6.9 AnnotationConfiguration is deprecated and it's functionality has been included in Configuration. I am using following code to build session factory.

As for as I understand the hibernate application should work fine with org.hibernate.annotations.Entity as well as long as I am using hibernate-annotations-3.5.6-Final.

Can you please suggest what might be the possible root cause of this strange behavior ?
Ranch Hand
Posts: 257
Hibernate Oracle Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey Jyoti,

org.hibernate.annotations.Entity has been deprecated and was planned to be removed in Hibernate 4.1. The link of same is as attached below

  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!