Brett Meyer commented on Bug HHH-7674

The locks are created by this in testLazyCollectionLoadingWithClearedSession:
store.getInventories().size();

In AbstractPersistentCollection#readSize, withTemporarySessionIfNeeded gets called multiple times in order to init and read the collection. I'm not 100% clear on the sequence, but it needs stepped through to make sure temp sessions are getting closed.

Although, that brings up a question. If the test does not call s.clear(), AbstractPersistentCollection uses that session. If s.clear() is called, a temp session is created. Should the cleared session be passed and used by AbstractPersistentCollection, or is creating a temp session expected?

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira