9 Replies Latest reply on Dec 14, 2006 6:51 AM by German de la Cruz

    Seam and myfaces 1.1.4-SNAPSHOT

    German de la Cruz Newbie

      People,

      Has anyone probe seam with myfaces 1.1.4-SNAPSHOT (The one in the apache snapshots maven repository)?. I receive an strange error with EVENT scope session Bean.

      I can't reproduce it with myfaces 1.1.2. The problem is the following.

      Seam use a WebRequestContext to store Event scoped SFSB. in the typ eof context, it is used the web request to store components.

      I've notice that in some occations, the appserver make a request after seam destroy the event scoped SFSB. As the request is the same, and it isn't cleaned, It has a reference in the request to a SFSB which has already been destroyed. Then, I received a "EJBObjectNotFoundException".

      I'm thinking in patch seam to correct it. But I'm not sure if it is already a patch or if it is my mistake

      I wonder if someone can help me.

      Thanks

      This is the stacktrace
      German.-

      
      
      21:31:54,308 DEBUG [Lifecycle] >>> Begin web request
      21:31:54,309 DEBUG [Component] seam component not found: org.jboss.seam.security.authenticator
      21:31:54,332 DEBUG [RepositoryClassLoader] setRepository, repository=org.jboss.mx.loading.HeirarchicalLoaderRepository3@5aa4bd97, cl=org.jboss.mx.loading.HeirarchicalLoaderRepository3$CacheClassLoader@633f4aeb{ url=null ,addedOrder=0}
      21:31:54,339 DEBUG [Component] instantiating Seam component: org.jboss.seam.core.manager
      21:31:54,340 DEBUG [Component] initializing new instance of: or
      
      ....
      
      21:32:12,008 DEBUG [SeamVariableResolver] resolved name to Seam component
      21:32:12,009 DEBUG [Manager] Storing conversation state: 8
      21:32:12,009 DEBUG [Lifecycle] flushing page context
      21:32:12,031 DEBUG [Lifecycle] After render response, destroying contexts
      21:32:12,031 DEBUG [Component] seam component not found: org.jboss.seam.security.authenticator
      21:32:12,031 DEBUG [Lifecycle] destroying event context
      21:32:12,031 DEBUG [Contexts] destroying: org.jboss.seam.core.manager
      21:32:12,031 DEBUG [Contexts] destroying: class org.apache.myfaces.shared_tomahawk.renderkit.html.util.JavascriptUtils.OLD_VIEW_ID
      21:32:12,031 DEBUG [Contexts] destroying: org.apache.myfaces.SCROLL_HIDDEN_INPUT_searchForm
      21:32:12,031 DEBUG [Contexts] destroying: msgs
      21:32:12,031 DEBUG [Contexts] destroying: breedFinder
      21:32:12,031 DEBUG [ExtendedPersistenceContextPropagationInterceptor] ++++ LongLivedSessionPropagationInterceptor
      21:32:12,031 DEBUG [Contexts] destroying: javax.faces.component.UIForm.org.apache.myfaces.HIDDEN_COMMAND_INPUTS_SET_dataTableForm
      21:32:12,032 DEBUG [Contexts] destroying: javax.faces.component.UIForm.org.apache.myfaces.HIDDEN_COMMAND_INPUTS_SET__id50:dynamicForm
      21:32:12,032 DEBUG [Contexts] destroying: org.apache.myfaces.custom.navmenu.htmlnavmenu.HtmlPanelNavigationMenu.PREVIOUS_VIEW_ROOT
      21:32:12,032 DEBUG [Contexts] destroying: org.apache.myfaces.application.jsp.JspStateManagerImpl.RESTORED_SERIALIZED_VIEW
      21:32:12,032 DEBUG [Contexts] destroying: specieFinder
      21:32:12,032 DEBUG [ExtendedPersistenceContextPropagationInterceptor] ++++ LongLivedSessionPropagationInterceptor
      21:32:12,032 DEBUG [Contexts] destroying: org.apache.myfaces.renderkit.html.util.DummyFormUtils.DUMMY_FORM_INFO
      21:32:12,032 DEBUG [Contexts] destroying: org.apache.myfaces.application.jsp.JspStateManagerImpl.SERIALIZED_VIEW
      21:32:12,032 DEBUG [Contexts] destroying: org.apache.myfaces.SCROLL_HIDDEN_INPUT__id50:dynamicForm
      21:32:12,032 DEBUG [Contexts] destroying: org.apache.myfaces.AddResourceFactory.CACHE_MAP_KEY
      21:32:12,032 DEBUG [Contexts] destroying: javax.faces.component.UIForm.org.apache.myfaces.HIDDEN_COMMAND_INPUTS_SET_searchForm
      21:32:12,032 DEBUG [Contexts] destroying: org.apache.myfaces.component.html.util.ExtensionFilter.doFilterCalled
      21:32:12,032 DEBUG [Contexts] destroying: facelets.Encoding
      21:32:12,032 DEBUG [Contexts] destroying: org.apache.myfaces.SCROLL_HIDDEN_INPUT_dataTableForm
      21:32:12,032 DEBUG [Contexts] destroying: jsf_sequence
      21:32:12,032 DEBUG [Contexts] destroying: com.sun.facelets.legacy.ELCONTEXT
      21:32:12,032 DEBUG [Lifecycle] flushing server-side conversation context
      21:32:12,032 DEBUG [Lifecycle] <<< End web request
      

      you can see, it is destroy... "21:32:12,032 DEBUG [Contexts] destroying: specieFinder"

      continuing in the same request....
      21:32:12,033 DEBUG [AbstractSeamPhaseListener] No active conversation context
      21:32:22,178 DEBUG [Lifecycle] >>> Begin web request
      21:32:22,179 DEBUG [Component] seam component not found: org.jboss.seam.security.authenticator
      21:32:22,185 DEBUG [RepositoryClassLoader] setRepository, repository=org.jboss.mx.loading.HeirarchicalLoaderRepository3@5aa4bd97, cl=org.jboss.mx.loading.HeirarchicalLoaderRepository3$CacheClassLoader@5b757c3a{ url=null ,addedOrder=0}
      21:32:22,207 DEBUG [Component] instantiating Seam component: org.jboss.seam.core.manager
      21:32:22,207 DEBUG [Component] initializing new instance of: org.jboss.seam.core.manager
      21:32:22,208 DEBUG [Manager] Restoring conversation with id: 8
      21:32:22,208 DEBUG [AbstractSeamPhaseListener] After restoring conversation context: ConversationContext(8)
      21:32:22,209 DEBUG [SeamVariableResolver] resolving name: breedEditor
      21:32:22,809 DEBUG [Contexts] found in conversation context: breedEditor
      21:32:22,809 DEBUG [SeamVariableResolver] resolved name to Seam component
      21:32:22,809 DEBUG [ExtendedPersistenceContextPropagationInterceptor] ++++ LongLivedSessionPropagationInterceptor
      21:32:22,810 DEBUG [Component] instantiating Seam component: b
      
      ....
      
      
      21:32:47,317 DEBUG [Contexts] destroying: msgs
      21:32:47,317 DEBUG [Contexts] destroying: javax.faces.component.UIForm.org.apache.myfaces.HIDDEN_COMMAND_INPUTS_SET_dataTableForm
      21:32:47,317 DEBUG [Contexts] destroying: org.apache.myfaces.renderkit.html.util.DummyFormUtils.DUMMY_FORM_INFO
      21:32:47,317 DEBUG [Contexts] destroying: specieFinder
      21:32:47,317 DEBUG [StatefulSessionFilePersistenceManager] Attempting to activate; id=3j001-esf1np-er5g8vyf-1-er5jna97-39
      21:32:47,317 DEBUG [StatefulSessionFilePersistenceManager] Reading session state from: /tmp/jboss4/default/tmp/sessions/SpecieFinderBean-er5jiad8-2p/3j001-esf1np-er5g8vyf-1-er5jna97-39.ser
      21:32:47,318 ERROR [STDERR] javax.ejb.EJBNoSuchObjectException: Could not find Stateful bean: 3j001-esf1np-er5g8vyf-1-er5jna97-39
      21:32:47,318 ERROR [STDERR] at org.jboss.ejb3.cache.simple.SimpleStatefulCache.get(SimpleStatefulCache.java:266)
      21:32:47,318 ERROR [STDERR] at org.jboss.ejb3.stateful.StatefulInstanceInterceptor.invoke(StatefulInstanceInterceptor.java:59)
      21:32:47,318 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      21:32:47,318 ERROR [STDERR] at org.jboss.ejb3.stateful.StatefulRemoveInterceptor.invoke(StatefulRemoveInterceptor.java:81)
      21:32:47,318 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      21:32:47,318 ERROR [STDERR] at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:78)
      21:32:47,318 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      21:32:47,318 ERROR [STDERR] at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:47)
      21:32:47,318 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      21:32:47,319 ERROR [STDERR] at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
      21:32:47,319 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
      21:32:47,319 ERROR [STDERR] at org.jboss.ejb3.stateful.StatefulContainer.localInvoke(StatefulContainer.java:188)
      21:32:47,319 ERROR [STDERR] at org.jboss.ejb3.stateful.StatefulLocalProxy.invoke(StatefulLocalProxy.java:98)
      21:32:47,319 ERROR [STDERR] at $Proxy309.destroy(Unknown Source)
      21:32:47,319 ERROR [STDERR] at manchot.actions.SpecieFinder$$FastClassByCGLIB$$7265d8d8.invoke(<generated>)
      21:32:47,319 ERROR [STDERR] at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
      21:32:47,319 ERROR [STDERR] at org.jboss.seam.interceptors.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:73)
      21:32:47,319 ERROR [STDERR] at org.jboss.seam.ejb.SeamInterceptor.invokeInContexts(SeamInterceptor.java:177)
      21:32:47,319 ERROR [STDERR] at org.jboss.seam.ejb.SeamInterceptor.invoke(SeamInterceptor.java:143)
      21:32:47,319 ERROR [STDERR] at org.jboss.seam.ejb.SeamInterceptor.aroundInvoke(SeamInterceptor.java:130)
      21:32:47,319 ERROR [STDERR] at org.jboss.seam.interceptors.ClientSideInterceptor.interceptInvocation(ClientSideInterceptor.java:44)
      21:32:47,319 ERROR [STDERR] at org.jboss.seam.interceptors.ClientSideInterceptor.intercept(ClientSideInterceptor.java:38)
      21:32:47,319 ERROR [STDERR] at manchot.actions.SpecieFinder$$EnhancerByCGLIB$$a4767741.destroy(<generated>)
      21:32:47,319 ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      21:32:47,319 ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      21:32:47,319 ERROR [STDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      21:32:47,319 ERROR [STDERR] at java.lang.reflect.Method.invoke(Method.java:585)
      21:32:47,319 ERROR [STDERR] at org.jboss.seam.util.Reflections.invoke(Reflections.java:17)
      21:32:47,347 ERROR [STDERR] at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:82)
      21:32:47,347 ERROR [STDERR] at org.jboss.seam.Component.callComponentMethod(Component.java:1476)
      21:32:47,347 ERROR [STDERR] at org.jboss.seam.Component.callDestroyMethod(Component.java:1464)
      21:32:47,347 ERROR [STDERR] at org.jboss.seam.contexts.Contexts.destroy(Contexts.java:189)
      21:32:47,347 ERROR [STDERR] at org.jboss.seam.contexts.Lifecycle.flushAndDestroyContexts(Lifecycle.java:638)
      21:32:47,347 ERROR [STDERR] at org.jboss.seam.contexts.Lifecycle.endRequest(Lifecycle.java:492)
      21:32:47,347 ERROR [STDERR] at org.jboss.seam.jsf.SeamPhaseListener.afterPhase(SeamPhaseListener.java:112)
      21:32:47,347 ERROR [STDERR] at org.apache.myfaces.lifecycle.PhaseListenerManager.informPhaseListenersAfter(PhaseListenerManager.java:89)
      21:32:47,347 ERROR [STDERR] at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:391)
      21:32:47,347 ERROR [STDERR] at javax.faces.webapp.FacesServlet.service(FacesServlet.java:138)
      21:32:47,347 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
      21:32:47,347 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      21:32:47,347 ERROR [STDERR] at org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:144)
      21:32:47,347 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      21:32:47,348 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      21:32:47,348 ERROR [STDERR] at org.jboss.seam.servlet.SeamRedirectFilter.doFilter(SeamRedirectFilter.java:30)
      21:32:47,348 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      21:32:47,348 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      21:32:47,348 ERROR [STDERR] at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
      21:32:47,348 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      21:32:47,348 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      21:32:47,348 ERROR [STDERR] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
      21:32:47,348 ERROR [STDERR] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
      21:32:47,348 ERROR [STDERR] at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
      21:32:47,348 ERROR [STDERR] at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
      21:32:47,348 ERROR [STDERR] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
      21:32:47,348 ERROR [STDERR] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
      21:32:47,348 ERROR [STDERR] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
      21:32:47,348 ERROR [STDERR] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
      21:32:47,348 ERROR [STDERR] at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
      21:32:47,348 ERROR [STDERR] at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
      21:32:47,348 ERROR [STDERR] at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
      21:32:47,348 ERROR [STDERR] at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
      21:32:47,348 ERROR [STDERR] at java.lang.Thread.run(Thread.java:595)
      21:32:47,348 WARN [Contexts] Could not destroy component: specieFinder
      



      The difference in time is dued to I was debbuging... :D

      don't be confused with se serialization Isse. I've an entire day with this. It is caused by de way jboss active a SFSB. You can see it in SimpleStatefulCache class in jboss-ejb3 code. If jboss can't find the reference in the cache (This is the case, as it has been destroyed) it tries to get it from serialization. As it isn't there too, jboss throws the exception