Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[eclipselink-users] Sharing EclipseLink Connection with legacy JDBC-code


Hello everyone,

is it possible to share an EclipseLink Connection with a regular JDBC Connection?

Imagine an application which consists of several JDBC queries/statements inside one transaction. I'd like to do some refactoring and replace some old JDBC code with JPA using EclipseLink.

Is it possible that EclipseLink is using the same Connection as the legacy JDBC code, so that it "sees" the uncommited data which have been made before and that regular JDBC which will be executed afterwards can see the changed data for EclipseLink?

(of course, the I have to call flush() the entitymanager)

If it's not possible - what would you suggest for such a refactoring?

Thank you!

Best regards,
Patric




Back to the top