• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JPA

 
Nikhil Jain
Ranch Hand
Posts: 392
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have just learning JPA[Java Persistence API]. I am getting confused from the earlier hibernate api & ejb3 entity [JPA].
How is JPA different from the earlier hibernate? I mean prior to EJB3, people were using hibernate for ORM. Is there anything new in the new spec that is provided by the Sun.

Thanks in advance
Shashank
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hibernate now implements the JPA spec. But you can still get to the hibernate specific classes and apis, and also to Hibernate added value on top of JPA. However, when you use those classes and enhancements that Hibernate makes over JPA, just like with other ORMs, that code will only work in the ORM tool that you chose.

But if you stick with the JPA apis and spec then all your code will be portable to any ORM that implements JPA like Hibernate.

Mark
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic