Bug 839630 - Exception is thrown when session with Spring Transaction Manager is being disposed
Exception is thrown when session with Spring Transaction Manager is being dis...
Status: VERIFIED
Product: JBoss Enterprise BRMS Platform 5
Classification: JBoss
Component: BRE (Expert, Fusion) (Show other bugs)
BRMS 5.3.1
Unspecified Unspecified
unspecified Severity high
: ---
: ---
Assigned To: Tihomir Surdilovic
Radovan Synek
:
Depends On:
Blocks: 843917
  Show dependency treegraph
 
Reported: 2012-07-12 09:05 EDT by Radovan Synek
Modified: 2013-10-07 18:50 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
error stacktrace (1.21 KB, text/plain)
2012-07-12 09:05 EDT, Radovan Synek
no flags Details

  None (edit)
Description Radovan Synek 2012-07-12 09:05:28 EDT
Created attachment 597804 [details]
error stacktrace

Description of problem:
Having several stateful knowledge sessions configured with JPA and Spring Transaction Manager. When these sessions are being disposed, following exception is thrown:

java.lang.IllegalStateException: EntityManager is closed
	at org.hibernate.ejb.EntityManagerImpl.getSession(EntityManagerImpl.java:66)
...
(see an attachment for the complete stacktrace)	


Additional info:
Problem is connected with application-scoped entity manager, which is shared between sessions within the same thread. After the first session with original entity manager is disposed, the other sessions see that entity manager closed and are unable to complete the dispose command.

The reproducer will be added soon.
Comment 1 Radovan Synek 2012-07-12 09:21:23 EDT
The promised reproducer:
https://github.com/droolsjbpm/droolsjbpm-integration/pull/30
Comment 2 Radovan Synek 2012-08-10 08:31:56 EDT
fixed by this commit:

https://github.com/droolsjbpm/drools/commit/96b4bae1a494b1dc8d2cb92ee263d7da209cc02f
Comment 3 Radovan Synek 2012-08-10 08:32:40 EDT
verified on 5.3.0.BRMS-P01

Note You need to log in before you can comment on or make changes to this bug.