Hi.
I had a statefule session bean. After invocation, I tried to remove it so that 
resource hold by it can be released, but I got a NoSuchObjectLocalException 
exception.
10:12:41,552,LogInterceptor] EJBException in method: public abstract void 
javax.ejb.EJBLocalObject.remove() throws 
javax.ejb.RemoveException,javax.ejb.EJBException
javax.ejb.NoSuchObjectLocalException: Could not activate; failed to restore 
state; CausedByException is:
        
/opt/jboss-3.2.6/server/default/tmp/sessions/DBFacade-e8slfflc-3/e8ux8e11-3g.ser
 (No such file or directory)    at 
org.jboss.ejb.plugins.StatefulSessionInstanceInterceptor.invoke(StatefulSessionInstanceInterceptor.java:210)
 at 
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:84)
        at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:315)
        at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:148)     at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:111)  
     at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191) at 
org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
   at 
org.jboss.ejb.StatefulSessionContainer.internalInvoke(StatefulSessionContainer.java:449)
     at org.jboss.ejb.Container.invoke(Container.java:709)   at 
org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invoke(BaseLocalProxyFactory.java:419)
     at 
org.jboss.ejb.plugins.local.StatefulSessionProxy.invoke(StatefulSessionProxy.java:41)
        


My code is like this 

  | DBFacadeLocal serverFacade = null;
  | DBFacadeLocal clientFacade = n
  | UserTransaction ut = getUserTransaction();
  |  try
  | {
  |            
  |  serverFacade = ...create one EJB.
  | clientFacade = ...create anothet EJB of the same type.
  | ut.beginTransaction().
  |         ...do work here.
  | ut.commit();
  | } catch (Exception e)
  | {
  |             try
  |             {
  |                 ut.rollback();
  |             } catch (Exception e1)
  |             {
  |                 //ignore
  |             }
  | 
  | 
  | } finally
  |         {
  |            
  | 
  |                     try
  |                     {
  |                             if (serverFacade != null)
  |                                 serverFacade.remove();
  |                     } catch(Exception e)
  |                     {                           
  |                     }
  |                    try
  |                  {
  |                      if (clientFacade != null)
  |                           clientFacade.remove();
  |                 } catch(Exception e)
  |                {   
  |                     //exception occure here.
  |                 }
  |         } 
  | 
  | 

What could be the cause for this? Help is appreciated.


View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3878146#3878146

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3878146


-------------------------------------------------------
This SF.Net email is sponsored by Oracle Space Sweepstakes
Want to be the first software developer in space?
Enter now for the Oracle Space Sweepstakes!
http://ads.osdn.com/?ad_idt12&alloc_id344&op=click
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to