Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » UnitOfWork parent(ClientSession) turns inActive
UnitOfWork parent(ClientSession) turns inActive [message #1794152] Fri, 24 August 2018 13:33 Go to next message
Rohan Rele is currently offline Rohan ReleFriend
Messages: 7
Registered: July 2018
Junior Member
Hello folks,

I am working on EclipseLink 2.7.0 with native non-JPA API.

The ClientSession is obtained from sessions.xml[].

Once a UnitOfWork is acquired from the ClientSession and commit() is called, I get NPE as the isActive property of the ClientSession is false.
This indicates that the ClientSession probably is released.

However in Toplink even after isActive property of ClientSession is false, the UnitOfWork#commit() call works fine.

Is this a bug in Eclipselink or is there any timeout causing the ClientSession to be inactive.

Please advise.

Re: UnitOfWork parent(ClientSession) turns inActive [message #1795875 is a reply to message #1794152] Mon, 01 October 2018 15:22 Go to previous message
Chris Delahunt is currently offline Chris DelahuntFriend
Messages: 1389
Registered: July 2009
Senior Member
I'm not aware of any bug. You have another thread open where you are getting an NPE in your UnitOfWork which is likely related to this one - another thread is using the same ClientSession/UnitOfWork and releasing the resources on your active thread, by closing them.

These items are not thread safe, and instead are meant to be obtained and discarded as needed by individual threads. Please ensure each thread has its own for access, and that objects read from them are not passed around either - many will have links back to the session they were read from if they are read from a UnitOfWork.

Best Regards,
Previous Topic:Toplink to Eclipselink migration
Next Topic:Cache L2 sharing objects with managed entities
Goto Forum:

Current Time: Tue May 30 22:27:40 GMT 2023

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

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

Back to the top