1 Reply Latest reply on Jul 7, 2006 1:14 AM by Basel Al-Mustafa

    NullPointerException when adding SeamPhaseListener and jboss

    Basel Al-Mustafa Newbie

      I have a simple application that uses JSF RI 1.2, Facelets 1.1.11, and Seam 1.0.1GA running under the JEMS installer version of JBoss. The application works fine except when adding the following two entries:

      <lifecycle>
       <phase-listener>org.jboss.seam.jsf.SeamPhaseListener</phase-listener>
      </lifecycle>
      
      and
      
      <module>
       <java>jboss-seam.jar</java>
      </module>
      


      to seam_01.ear/seam_01.war/WEB-INF/faces-config.xml and seam_01.ear/META-INF/applicatoin.xml respectively. Here is the complete stack:



      2006-07-07 20:12:37,948 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/seam_01].[Faces Servlet]] Servlet.service() for servlet Faces Servlet threw exception
      java.lang.NullPointerException
       at org.jboss.seam.jsf.SeamViewHandler.calculateLocale(SeamViewHandler.java:32)
       at com.sun.facelets.FaceletViewHandler.calculateLocale(FaceletViewHandler.java:771)
       at com.sun.faces.application.ViewHandlerImpl.createView(ViewHandlerImpl.java:340)
       at org.jboss.seam.jsf.SeamViewHandler.createView(SeamViewHandler.java:43)
       at com.sun.facelets.FaceletViewHandler.createView(FaceletViewHandler.java:782)
       at com.sun.faces.lifecycle.RestoreViewPhase.execute(RestoreViewPhase.java:219)
       at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:266)
       at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:132)
       at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)
       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.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
       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)
      


      What did I do wrong?