0 Replies Latest reply on Feb 3, 2015 2:00 PM by akash bansal

    ContextNotActiveException: Conversation Context not active when method called on conversation Transient conversation

    akash bansal Newbie

      Hi SMEs,

       

      I am using JBoss 6.1. I have two EARs, and each EAR is having one WAR. I am using Seam Framework. I have configured Ldap Login module for authentication. Each WAR is using this Ldap Login Module. When I logs in into first WAR Web Application, I am able to login automatically into second WAR web application.

       

      But when I try to logging out from first WAR web application, it throws following exception:

       

      javax.faces.el.EvaluationException: javax.enterprise.context.ContextNotActiveException: Conversation Context not active when method called on conversation Transient conversation

          at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:101)

          at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:101)

          at javax.faces.component.UICommand.broadcast(UICommand.java:315)

          at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:786)

          at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1251)

          at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:81)

          at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)

          at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)

          at javax.faces.webapp.FacesServlet.service(FacesServlet.java:593)

          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:295)

          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)

          at org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:357)

          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246)

          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)

          at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)

          at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149)

          at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:481)

          at org.jboss.as.jpa.interceptor.WebNonTxEmCloserValve.invoke(WebNonTxEmCloserValve.java:50)

          at org.jboss.as.jpa.interceptor.WebNonTxEmCloserValve.invoke(WebNonTxEmCloserValve.java:50)

          at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169)

          at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:145)

          at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97)

          at org.apache.catalina.authenticator.SingleSignOn.invoke(SingleSignOn.java:408)

          at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102)

          at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:336)

          at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)

          at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653)

          at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:920)

          at java.lang.Thread.run(Thread.java:662)

      Caused by: javax.enterprise.context.ContextNotActiveException: Conversation Context not active when method called on conversation Transient conversation

          at org.jboss.weld.context.conversation.ConversationImpl.verifyConversationContextActive(ConversationImpl.java:197)

          at org.jboss.weld.context.conversation.ConversationImpl.touch(ConversationImpl.java:159)

          at org.jboss.weld.context.conversation.ConversationImpl.<init>(ConversationImpl.java:72)

          at org.jboss.weld.bean.builtin.ConversationBean.create(ConversationBean.java:48)

          at org.jboss.weld.bean.builtin.ConversationBean.create(ConversationBean.java:17)

          at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:101)

          at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:90)

          at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:104)

          at org.jboss.weld.proxies.Conversation$1987778082$Proxy$_$$_WeldClientProxy.getId(Conversation$1987778082$Proxy$_$$_WeldClientProxy.java)

          at org.jboss.seam.faces.context.conversation.ConversationBoundaryInterceptor.handleExceptionEnd(ConversationBoundaryInterceptor.java:103)

          at org.jboss.seam.faces.context.conversation.ConversationBoundaryInterceptor.around(ConversationBoundaryInterceptor.java:69)

          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.weld.interceptor.proxy.SimpleMethodInvocation.invoke(SimpleMethodInvocation.java:30)

          at org.jboss.weld.interceptor.proxy.SimpleInterceptionChain.invokeNextInterceptor(SimpleInterceptionChain.java:69)

          at org.jboss.weld.interceptor.proxy.InterceptorMethodHandler.executeInterception(InterceptorMethodHandler.java:112)

          at org.jboss.weld.interceptor.proxy.InterceptorMethodHandler.invoke(InterceptorMethodHandler.java:88)

          at org.jboss.weld.bean.proxy.CombinedInterceptorAndDecoratorStackMethodHandler.invoke(CombinedInterceptorAndDecoratorStackMethodHandler.java:55)

          at com.ngt.sof.presentation.action.LogoutAction$Proxy$_$$_WeldSubclass.logout(LogoutAction$Proxy$_$$_WeldSubclass.java)

          at com.ngt.sof.presentation.action.LogoutAction$Proxy$_$$_WeldClientProxy.logout(LogoutAction$Proxy$_$$_WeldClientProxy.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.apache.el.parser.AstValue.invoke(AstValue.java:258)

          at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:278)

          at org.jboss.weld.util.el.ForwardingMethodExpression.invoke(ForwardingMethodExpression.java:40)

          at org.jboss.weld.el.WeldMethodExpression.invoke(WeldMethodExpression.java:50)

          at com.sun.faces.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:105)

          at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:87)

          ... 28 more

       

      I am using following code when I try to log out from web applications:

       

      FacesContext.getCurrentInstance().getExternalContext().invalidateSession();

       

      I request you guys to please help me in this regard.

       

      Thanks,

      Akash Bansal