2 Replies Latest reply on Jul 26, 2007 8:35 AM by henrik lindberg

    exception during destroy... need help

    henrik lindberg Apprentice

      I get the exception below when the session context times out, and a stateful bean in conversation is destroyed. I have no clue as to how to get rid of this exception.

      Any hint is of value.

      I am running seam 2.0 Beta 1 and Jboss 4.2.1.GA.

      00:39:24,109 WARN [Component] Exception calling stateful session bean default @Remove method: linkFactory
      javax.ejb.EJBException: javax.el.PropertyNotFoundException: Property 'facesContext' not found on type org.jboss.seam.Namespace
       at org.jboss.ejb3.tx.Ejb3TxPolicy.handleExceptionInOurTx(Ejb3TxPolicy.java:63)
       at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:83)
       at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:191)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.ejb3.stateful.StatefulInstanceInterceptor.invoke(StatefulInstanceInterceptor.java:83)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.ejb3.stateful.StatefulRemoveInterceptor.invoke(StatefulRemoveInterceptor.java:97)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)
       at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:106)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.ejb3.stateful.StatefulContainer.localInvoke(StatefulContainer.java:204)
       at org.jboss.ejb3.stateful.StatefulLocalProxy.invoke(StatefulLocalProxy.java:100)
       at $Proxy160.destroy(Unknown Source)
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.seam.util.Reflections.invoke(Reflections.java:21)
       at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:31)
       at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:72)
       at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:56)
       at org.jboss.seam.ejb.RemoveInterceptor.aroundInvoke(RemoveInterceptor.java:41)
       at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
       at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:106)
       at org.jboss.seam.intercept.ClientSideInterceptor.invoke(ClientSideInterceptor.java:50)
       at org.javassist.tmp.java.lang.Object_$$_javassist_39.destroy(Object_$$_javassist_39.java)
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.seam.util.Reflections.invoke(Reflections.java:21)
       at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:124)
       at org.jboss.seam.Component.callComponentMethod(Component.java:1975)
       at org.jboss.seam.Component.callDefaultRemoveMethod(Component.java:1886)
       at org.jboss.seam.Component.destroy(Component.java:1245)
       at org.jboss.seam.contexts.Contexts.destroy(Contexts.java:251)
       at org.jboss.seam.contexts.Contexts.destroyConversationContext(Contexts.java:413)
       at org.jboss.seam.contexts.Lifecycle.endSession(Lifecycle.java:236)
       at org.jboss.seam.contexts.ServletLifecycle.endSession(ServletLifecycle.java:132)
       at org.jboss.seam.servlet.SeamListener.sessionDestroyed(SeamListener.java:49)
       at org.apache.catalina.session.StandardSession.expire(StandardSession.java:702)
       at org.apache.catalina.session.StandardSession.isValid(StandardSession.java:592)
       at org.apache.catalina.session.ManagerBase.processExpires(ManagerBase.java:682)
       at org.apache.catalina.session.ManagerBase.backgroundProcess(ManagerBase.java:667)
       at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1286)
       at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1571)
       at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1580)
       at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1580)
       at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1560)
       at java.lang.Thread.run(Thread.java:619)
      


        • 1. Re: exception during destroy... need help
          Dmitriy Lapko Newbie

          May be you should take a look at methods marked with @Remove annotation - it looks like they try to invoke methods of facesContext object.
          Do you have SFSB linkFactory? May be the problem in its @Remove method.

          • 2. Re: exception during destroy... need help
            henrik lindberg Apprentice

            It is a SFSB in Conversation scope. It's remove method does nothing.
            I have two things injected

             @In(required=true, value="#{basePath}")
             private String m_basePath;
            
             @In(required=true, value="#{jws_xx}")
             private String m_jws_xx;
            

            and both of these are declared in components.xml - like this
            <factory name="basePath" value="#{facesContext.externalContext.request.scheme}://#{facesContext.externalContext.request.serverName}:#{facesContext.externalContext.request.serverPort}#{facesContext.externalContext.request.contextPath}/"
            />
            <factory name="jws_xx" value="jws_1.1" />
            

            And the reference to facesContext is in the "basePath". That is the only place. So, what could be referencing the facesContext at point of destruction?
            Do I need to clear injected variables?