6 Replies Latest reply on Jul 22, 2006 12:37 AM by Rani Kav

    Problem while deploying JBoss Seam on Tomcat 5.5.17

    Kapil Kashyap Newbie

      Hi,

      This is Kapil Kashyap, and I am a new member of this JBoss Forum.Well I am trying to work with the new JBoss Seam Framework and have successfully deployed it on JBoss, but am getting the below error message when trying to deploy it on Tomcat 5.5.17

      Tomcat version - 5.5.17
      Using JDK 1.5


      INFO 28-06 15:40:55,375 (Log4JLogger.java:info:94) -no pages.xml file found
      INFO 28-06 15:40:55,718 (Log4JLogger.java:info:94) -No context init parameter 'org.apache.myfaces.PRETTY_HTML' found,
      using default value true
      INFO 28-06 15:40:55,718 (Log4JLogger.java:info:94) -No context init parameter 'org.apache.myfaces.ALLOW_JAVASCRIPT' fo
      und, using default value true
      INFO 28-06 15:40:55,718 (Log4JLogger.java:info:94) -Tomahawk jar not available. Autoscrolling, DetectJavascript, AddRe
      sourceClass and CheckExtensionsFilter are disabled now.
      INFO 28-06 15:41:03,031 (Log4JLogger.java:info:94) -Hibernate Annotations 3.2.0.CR1
      ERROR 28-06 15:41:03,140 (Log4JLogger.java:error:119) -Servlet.service() for servlet Faces Servlet threw exception
      javax.faces.FacesException: Error calling action method of component with id _idJsp0:_idJsp6
      at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
      at javax.faces.component.UICommand.broadcast(UICommand.java:106)
      at javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
      at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
      at org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:343)
      at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
      at org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:833)
      at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:639)
      at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1285)
      at java.lang.Thread.run(Unknown Source)
      Caused by: javax.faces.el.EvaluationException: Exception while invoking expression #{register.register}
      at org.apache.myfaces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:165)
      at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:63)
      ... 18 more
      Caused by: org.jboss.seam.InstantiationException: Could not instantiate Seam component: register
      at org.jboss.seam.Component.newInstance(Component.java:735)
      at org.jboss.seam.Component.newInstance(Component.java:1308)
      at org.jboss.seam.Component.getInstance(Component.java:1263)
      at org.jboss.seam.Component.getInstance(Component.java:1246)
      at org.jboss.seam.jsf.SeamVariableResolver.resolveVariable(SeamVariableResolver.java:44)
      at org.apache.myfaces.config.LastVariableResolverInChain.resolveVariable(LastVariableResolverInChain.java:42)
      at org.apache.myfaces.el.ValueBindingImpl$ELVariableResolver.resolveVariable(ValueBindingImpl.java:574)
      at org.apache.commons.el.NamedValue.evaluate(NamedValue.java:124)
      at org.apache.myfaces.el.ValueBindingImpl.resolveToBaseAndProperty(ValueBindingImpl.java:455)
      at org.apache.myfaces.el.MethodBindingImpl.resolveToBaseAndProperty(MethodBindingImpl.java:180)
      at org.apache.myfaces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:114)
      ... 19 more
      Caused by: javax.naming.NamingException: Local server is not initialized
      at org.jnp.interfaces.LocalOnlyContextFactory.getInitialContext(LocalOnlyContextFactory.java:45)
      at javax.naming.spi.NamingManager.getInitialContext(Unknown Source)
      at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source)
      at javax.naming.InitialContext.init(Unknown Source)
      at javax.naming.InitialContext.(Unknown Source)
      at org.jboss.seam.util.Naming.getInitialContext(Naming.java:26)
      at org.jboss.seam.util.Naming.getInitialContext(Naming.java:37)
      at org.jboss.seam.Component.instantiate(Component.java:774)
      at org.jboss.seam.Component.newInstance(Component.java:731)
      ... 29 more



      I would be very greatful if someone helps me out to resolve this issue.

      Thanks in advance.

      With Regards,
      Kapil Kashyap.

        • 1. Re: Problem while deploying JBoss Seam on Tomcat 5.5.17
          Kapil Kashyap Newbie

          Hi,

          This is Kapil Kashyap again. Well, I thought it would be better to give you the Exception Report rather than the Error on the Server. So here it is.


          type Exception report

          message

          description The server encountered an internal error () that prevented it from fulfilling this request.

          exception

          javax.servlet.ServletException: Error calling action method of component with id _idJsp0:_idJsp6
          javax.faces.webapp.FacesServlet.service(FacesServlet.java:152)

          root cause

          javax.faces.FacesException: Error calling action method of component with id _idJsp0:_idJsp6
          org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
          javax.faces.component.UICommand.broadcast(UICommand.java:106)
          javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
          javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
          org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:343)
          org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
          javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)



          Thanks in advance,
          With Regards,
          Kapil Kashyap.

          • 2. Re: Problem while deploying JBoss Seam on Tomcat 5.5.17
            James Richards Newbie

            I am seeing virtually the same error on JBoss 4.0.4 GA using the jboss-4.0.4.GA-Patch1-installer.jar installer which was recently released. Using a fresh "ejb3" install, I get the following error trying to run a single registration:

            """
            type Exception report

            message

            description The server encountered an internal error () that prevented it from fulfilling this request.

            exception

            javax.servlet.ServletException: Error calling action method of component with id _id0:_id6
            javax.faces.webapp.FacesServlet.service(FacesServlet.java:121)
            org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

            root cause

            javax.faces.FacesException: Error calling action method of component with id _id0:_id6
            org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
            javax.faces.component.UICommand.broadcast(UICommand.java:106)
            javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:90)
            javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:164)
            org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:316)
            org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
            javax.faces.webapp.FacesServlet.service(FacesServlet.java:106)
            org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
            """

            The full stack trace from the server side:

            """
            09:32:22,468 ERROR [[Faces Servlet]] Servlet.service() for servlet Faces Servlet threw exception
            javax.faces.FacesException: Error calling action method of component with id _id0:_id6
            at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
            at javax.faces.component.UICommand.broadcast(UICommand.java:106)
            at javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:90)
            at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:164)
            at org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:316)
            at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
            at javax.faces.webapp.FacesServlet.service(FacesServlet.java:106)
            at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
            at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
            at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
            at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
            at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
            at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
            at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
            at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
            at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
            at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
            at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
            at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
            at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
            at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
            at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
            at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
            at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
            at java.lang.Thread.run(Thread.java:595)
            Caused by: javax.faces.el.EvaluationException: Exception while invoking expression #{register.register}
            at org.apache.myfaces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:153)
            at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:63)
            ... 24 more
            Caused by: javax.ejb.EJBException: java.lang.RuntimeException: java.lang.NoSuchMethodError: javax.interceptor.InvocationContext.getTarget()Ljava/lang/Object;
            at org.jboss.ejb3.tx.Ejb3TxPolicy.handleExceptionInOurTx(Ejb3TxPolicy.java:69)
            at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:83)
            at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:197)
            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.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:62)
            at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
            at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:78)
            at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
            at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:47)
            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.stateless.StatelessContainer.localInvoke(StatelessContainer.java:181)
            at org.jboss.ejb3.stateless.StatelessLocalProxy.invoke(StatelessLocalProxy.java:79)
            at $Proxy128.register(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:585)
            at org.apache.myfaces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:129)
            ... 25 more
            Caused by: java.lang.RuntimeException: java.lang.NoSuchMethodError: javax.interceptor.InvocationContext.getTarget()Ljava/lang/Object;
            at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:128)
            at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
            at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
            at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
            at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
            at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:47)
            at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
            at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:79)
            ... 45 more
            Caused by: java.lang.NoSuchMethodError: javax.interceptor.InvocationContext.getTarget()Ljava/lang/Object;
            at org.jboss.seam.ejb.SeamInterceptor.aroundInvoke(SeamInterceptor.java:37)
            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:585)
            at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:118)
            ... 52 more
            """

            • 3. Re: Problem while deploying JBoss Seam on Tomcat 5.5.17
              Thomas Heute Master

              Use the Jems installer, see the getting started document on the JBoss Seam product page

              • 4. Re: Problem while deploying JBoss Seam on Tomcat 5.5.17
                Hafizur Rahman Newbie

                I also faced the same problem. However, using JBoss Seam 1.0.0 GA version resolves it.

                • 5. Re: Problem while deploying JBoss Seam on Tomcat 5.5.17
                  Rani Kav Newbie

                  I used JEMS installer and everything works from JBoss AS.
                  But, I keep getting this error in all TestNG tests for Seam. This happened after I upgraded to the JEMS version and switched Jboss IDE to 3.2 Alpha.
                  I understand I am using alpha software, but please don't release such software in future if you can avoid it.

                  Atleast, can someone tell me how I can fix this error now that I am in this state?

                  Caused by: javax.naming.NamingException: Local server is not initialized
                  at org.jnp.interfaces.LocalOnlyContextFactory.getInitialContext(LocalOnlyContextFactory.java:45)
                  at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:667)
                  at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:247)
                  at javax.naming.InitialContext.init(InitialContext.java:223)
                  at javax.naming.InitialContext.(InitialContext.java:197)
                  at org.jboss.seam.util.Naming.getInitialContext(Naming.java:26)
                  at org.jboss.seam.util.Naming.getInitialContext(Naming.java:37)
                  at org.jboss.seam.Component.instantiate(Component.java:774)
                  at org.jboss.seam.Component.newInstance(Component.java:731)

                  • 6. Re: Problem while deploying JBoss Seam on Tomcat 5.5.17
                    Rani Kav Newbie

                    Found the issue: Resources.getResourceAsStream("/WEB-INF/components.xml", servletContext);

                    I got it working by putting the components.xml in WEB-INF subfolder even for testng unit tests. If this was documented somewhere, then it was cleverly hidden. Obviously, I am not in a good mood as it wasted my evening.