Why Use Hibernate APIs Instead of JPA?

By timothynjones

Java Community News – Steve Ebersole on Hibernate 3.2 is an interview with one of the two leads for Hibernate 3.2 discussing, among other things, why one might want to use the proprietary Hibernate APIs directly instead of the standard JPA API that Hibernate implements. Notably:

  • Hibernate defines methods to allow the developer to manage the size of the persistence context.
  • Query-by-Criteria/Query-by-Example

There are a few more esoteric features in the Hibernate API, but for now I’m sticking with JPA. Outside of academic interest I’ve never seen much need for query-by-example. The ability to manage the size of a persistence context could be important, but for web-based applications which usually have a transaction per request I don’t think it will be necessary.

One Response to “Why Use Hibernate APIs Instead of JPA?”

  1. Pavel Says:

    Query by criteria is a really cool feature that I miss in JPA.

Leave a Reply