[jboss-jira] [JBoss JIRA] Closed: (JBAS-3717) correct TCL should be used before starting entity PMs
Alexey Loubyansky (JIRA)
jira-events at jboss.com
Fri Sep 29 11:59:41 EDT 2006
[ http://jira.jboss.com/jira/browse/JBAS-3717?page=all ]
Alexey Loubyansky closed JBAS-3717.
-----------------------------------
Fix Version/s: JBossAS-3.2.8.SP2
Resolution: Done
Fixed.
> correct TCL should be used before starting entity PMs
> -----------------------------------------------------
>
> Key: JBAS-3717
> URL: http://jira.jboss.com/jira/browse/JBAS-3717
> Project: JBoss Application Server
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: EJB2
> Affects Versions: JBossAS-4.0.5.CR1, JBossAS-3.2.8.SP1
> Reporter: Alexey Loubyansky
> Assigned To: Alexey Loubyansky
> Fix For: JBossAS-4.0.5.GA, JBossAS-3.2.8.SP2
>
>
> In EjbModule before starting persistence managers for entity beans, correct thread class loader should be set. Like so
> protected void startService() throws Exception
> {
> // before EntityContainer returns from the startService, its PM should be usable
> ListIterator iter = containerOrdering.listIterator();
> while( iter.hasNext() )
> {
> Container con = (Container) iter.next();
> if(con.getBeanMetaData().isEntity())
> {
> ClassLoader oldCl = SecurityActions.getContextClassLoader();
> SecurityActions.setContextClassLoader(con.getClassLoader());
> try
> {
> ((EntityContainer)con).getPersistenceManager().start();
> }
> finally
> {
> // Reset classloader
> SecurityActions.setContextClassLoader(oldCl);
> }
> }
> }
> ...
--
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 jboss-jira
mailing list