Bug 839630 - Exception is thrown when session with Spring Transaction Manager is being disposed
Summary: Exception is thrown when session with Spring Transaction Manager is being dis...
Keywords:
Status: VERIFIED
Alias: None
Product: JBoss Enterprise BRMS Platform 5
Classification: JBoss
Component: BRE (Expert, Fusion)
Version: BRMS 5.3.1
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: ---
Assignee: Nobody
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: 843917
TreeView+ depends on / blocked
 
Reported: 2012-07-12 13:05 UTC by Radovan Synek
Modified: 2023-05-31 22:25 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:
Type: Bug
Embargoed:


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

Description Radovan Synek 2012-07-12 13:05:28 UTC
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 13:21:23 UTC
The promised reproducer:
https://github.com/droolsjbpm/droolsjbpm-integration/pull/30

Comment 2 Radovan Synek 2012-08-10 12:31:56 UTC
fixed by this commit:

https://github.com/droolsjbpm/drools/commit/96b4bae1a494b1dc8d2cb92ee263d7da209cc02f

Comment 3 Radovan Synek 2012-08-10 12:32:40 UTC
verified on 5.3.0.BRMS-P01


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