[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1787) Injecting a Hibernate session with @PersistenceContext causes ClassCastException with the Seam Interceptor
Alex Grönholm (JIRA)
jira-events at lists.jboss.org
Sun Aug 12 12:51:05 EDT 2007
Injecting a Hibernate session with @PersistenceContext causes ClassCastException with the Seam Interceptor
----------------------------------------------------------------------------------------------------------
Key: JBSEAM-1787
URL: http://jira.jboss.com/jira/browse/JBSEAM-1787
Project: JBoss Seam
Issue Type: Bug
Components: EJB3
Affects Versions: 2.0.0.BETA1
Reporter: Alex Grönholm
Priority: Minor
SessionBeanInterceptor assumes that the field annotated with @PersistenceContext is of type EntityManager.
However, some containers, most notably JBoss AS, support injection of delegates such as Hibernate sessions.
While I don't have the faintest idea why the interceptor needs to proxy persistence contexts, but at the very least it should check the type with instanceOf before casting it to EntityManager.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the seam-issues
mailing list