When using Thread bound sessions, Hibernate Search FTSession creation fails if out of transaction

Description

See https://forum.hibernate.org/viewtopic.php?f=9&t=998336

It might be enough to add a note/warning somewhere in the documentation regarding the use ThreadLocalSessionContext.
Or maybe the code examples should all consistently open a transaction before getting the fulltext session.

Activity

Show:

Emmanuel Bernard January 5, 2010 at 12:59 PM

Added test. Will need either the latest Hibernate Core version (trunk atm and 3.3.x branch)

Emmanuel Bernard January 4, 2010 at 2:44 PM

Adjusting the title

Emmanuel Bernard January 4, 2010 at 2:42 PM

We should fix the Hibernate limitation rather than force a rather unintuitive behavior on users.

Sanne Grinovero December 31, 2009 at 5:37 PM

Emmanuel, assigning to you to draw your attention on this. I'm not having smart ides on this, I'd like to avoid the interceptor check from org.hibernate.context.ThreadLocalSessionContext if possible ?

Fixed

Details

Assignee

Reporter

Components

Fix versions

Priority

Created December 22, 2009 at 4:17 PM
Updated July 1, 2010 at 12:37 PM
Resolved January 5, 2010 at 12:59 PM