Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » JPA vs. Native
JPA vs. Native [message #376336] Fri, 11 July 2008 13:55 Go to next message
Mikhail Kadan is currently offline Mikhail KadanFriend
Messages: 61
Registered: July 2009

As I understand, server/client/historical/etc. sessions, advanced
transaction features (using UoW, nested sessions, etc.) are available only
if using EclipseLink native mechanism (creating descriptors with
Workbench, and then using SessionManager). And if I'm using JPA mechanism
(via EntityManager) I'm limited to a session similar to simple

I've discovered document named "Using EclipseLink JPA Extensions" ( ), but it
tells nothing about using this advanced features in JPA. Is it possible to
use advanced EclipseLink sessions in JPA or I have to follow only JPA spec
+ some extensions, described it this document?

Re: JPA vs. Native [message #376340 is a reply to message #376336] Fri, 11 July 2008 18:52 Go to previous message
Doug Clarke is currently offline Doug ClarkeFriend
Messages: 155
Registered: July 2009
Senior Member
Behind the EclipseLink JPA EntityManager implementation is a Client
Session and a UnitOfWork. The EntityManagerFactory wraps a ServerSession.
If you look at the JPAHelper class you will see how you can gain access to
the underlying classic/native API. stence/jpa/JpaHelper.html

You can use the classic API in conjunction with JPA through the use of
this helper class. We have been working to expose many of the advanced
features of EclipseLink through the JPA interface in a more seamless
fashion. Some of these have been completed for 1.0 but some remain as open

Example: Historical sessions through EclipseLink JPA currently requires
you to access the underlying classic API to create the historical session
or to create queries with As-Of. You will see we have some bugs filed to
address easier JPA usage of these:

Previous Topic:javax.persistence.TransactionRequiredException thrown on EntityManager.flush
Next Topic:Hard coded database plattforms...
Goto Forum:

Current Time: Sat May 26 00:49:38 GMT 2018

Powered by FUDForum. Page generated in 0.02156 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top