3 Replies Latest reply on Aug 15, 2010 2:08 AM by Dietrich Schulten

    NPE, Facelets, JBoss 5.1.0.GA, JDK 1.6.0-13

    Jules Lyons Newbie

      hi all...

       

          I have an application that is running fine in JBoss 4.2.3.GA, JDK 1.6.0-13.   Now, I'm trying to migrate to JBoss 5.1.0.GA.  I have a clean deployment, but JBoss hurls when trying to access a page (welcome page) with the following error:

       

      java.lang.NullPointerException
              at com.sun.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:49)
              at com.sun.facelets.impl.DefaultFacelet.apply(DefaultFacelet.java:95)
              at com.sun.facelets.FaceletViewHandler.buildView(FaceletViewHandler.java:408)
              at com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:442)
              at oracle.adfinternal.view.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:159)
              at org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:41)
              at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:132)
              at javax.faces.webapp.FacesServlet.service(FacesServlet.java:140)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
              at org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:147)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
              at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._invokeDoFilter(AdfFacesFilterImpl.java:279)
              at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._doFilterImpl(AdfFacesFilterImpl.java:248)
              at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl.doFilter(AdfFacesFilterImpl.java:172)
              at oracle.adf.view.faces.webapp.AdfFacesFilter.doFilter(AdfFacesFilter.java:80)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
              at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
              at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
              at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
              at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
              at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
              at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
              at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.jav
      a:126)
              at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java
      :70)
              at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
              at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
              at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
              at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
              at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
              at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
              at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
              at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

       

       

      I removed my el-api and el-ri jars due to another error.  But, I'm a little lost on the cause of this error.  If anyone has some idea, I would appreciate it.

       

      thx

        • 1. Re: NPE, Facelets, JBoss 5.1.0.GA, JDK 1.6.0-13
          Jules Lyons Newbie

          I'm able to get past the error, but running into this stack now:

           

           

          javax.servlet.ServletException: Could not instantiate feature[compiler.ExpressionFactory]: com.sun.el.ExpressionFactoryImpl
               javax.faces.webapp.FacesServlet.service(FacesServlet.java:154)
               org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:147)
               oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._invokeDoFilter(AdfFacesFilterImpl.java:279)
               oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._doFilterImpl(AdfFacesFilterImpl.java:248)
               oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl.doFilter(AdfFacesFilterImpl.java:172)
               oracle.adf.view.faces.webapp.AdfFacesFilter.doFilter(AdfFacesFilter.java:80)
               org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
          

           

           

           

          com.sun.facelets.FaceletException: Could not instantiate feature[compiler.ExpressionFactory]: com.sun.el.ExpressionFactoryImpl
               com.sun.facelets.compiler.Compiler.featureInstance(Compiler.java:152)
               com.sun.facelets.compiler.Compiler.createExpressionFactory(Compiler.java:141)
               com.sun.facelets.impl.DefaultFaceletFactory.createFacelet(DefaultFaceletFactory.java:190)
               com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:138)
               com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:89)
               com.sun.facelets.FaceletViewHandler.buildView(FaceletViewHandler.java:401)
               com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:442)
               oracle.adfinternal.view.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:159)
               org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:41)
               org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:132)
               javax.faces.webapp.FacesServlet.service(FacesServlet.java:140)
               org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:147)
               oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._invokeDoFilter(AdfFacesFilterImpl.java:279)
               oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._doFilterImpl(AdfFacesFilterImpl.java:248)
               oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl.doFilter(AdfFacesFilterImpl.java:172)
               oracle.adf.view.faces.webapp.AdfFacesFilter.doFilter(AdfFacesFilter.java:80)
               org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

           

           

          • 2. Re: NPE, Facelets, JBoss 5.1.0.GA, JDK 1.6.0-13
            Stan Silvert Master

            Try putting this in your web.xml:

             

            <context-param>
               <param-name>com.sun.faces.expressionFactory</param-name>
                 <param-value>org.apache.el.ExpressionFactoryImpl</param-value>
            </context-param>

             

            I'm not sure if that will fix it.  Please let me know.

             

            Stan

            • 3. Re: NPE, Facelets, JBoss 5.1.0.GA, JDK 1.6.0-13
              Dietrich Schulten Newbie

              At least in my case this does not help. I have the getting started sample up and running in the browser on glassfish 2.1, now I try to make it possible with maven. Part of the problem here is certainly to get the jetty classpath right :-(

               

              I tried to add el-impl-1.0.jar as a compile dependency, which apparently solves the above problem, but then I get to the next problem, a message about a missing ProjectStage enum (java.lang.NoClassDefFoundError). But that is a different story. I am not sure if it is related with el-impl.

               

               

              Dietrich