5 Replies Latest reply on Nov 21, 2007 6:00 PM by pmuir

    Richfaces configuration issues

    rvkishore

      I am trying to get Richfaces configured for my seam application. The richfaces user guide recommends a web.xml config

      web-app version="2.4"
      
       xmlns="http://java.sun.com/xml/ns/j2ee"
      
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      
       xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
      
      
      
       <!-- Seam -->
      
       <listener>
      
       <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>
      
       </listener>
      
      
      
       <!-- richfaces -->
      
       <filter>
      
       <display-name>RichFaces Filter</display-name>
      
       <filter-name>richfaces</filter-name>
      
       <filter-class>org.ajax4jsf.Filter</filter-class>
      
       </filter>
      
       <filter-mapping>
      
       <filter-name>richfaces</filter-name>
      
       <url-pattern>*.seam</url-pattern>
      
       </filter-mapping>
      
      
      
       <!-- Propagate conversations across redirects -->
      
       <filter>
      
       <filter-name>Seam Redirect Filter</filter-name>
      
       <filter-class>org.jboss.seam.servlet.SeamRedirectFilter</filter-class>
      
       </filter>
      
       <filter-mapping>
      
       <filter-name>Seam Redirect Filter</filter-name>
      
       <url-pattern>*.seam</url-pattern>
      
       </filter-mapping>
      
      
      
       <filter>
      
       <filter-name>Seam Exception Filter</filter-name>
      
       <filter-class>org.jboss.seam.servlet.SeamExceptionFilter</filter-class>
      
       </filter>
      
      
      
       <filter-mapping>
      
       <filter-name>Seam Exception Filter</filter-name>
      
       <url-pattern>*.jsf</url-pattern>
      
       </filter-mapping>
      
      
      
       <!-- JSF -->
      
       <context-param>
      
       <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
      
       <param-value>client</param-value>
      
       </context-param>
      
      
      
       <context-param>
      
       <param-name>org.ajax4jsf.VIEW_HANDLERS</param-name>
      
       <param-value>com.sun.facelets.FaceletViewHandler</param-value>
      
       </context-param>
      
      
      
       <context-param>
      
       <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
      
       <param-value>.xhtml</param-value>
      
       </context-param>
      
       <context-param>
      
       <param-name>facelets.REFRESH_PERIOD</param-name>
      
       <param-value>2</param-value>
      
       </context-param>
      
       <context-param>
      
       <param-name>facelets.DEVELOPMENT</param-name>
      
       <param-value>true</param-value>
      
       </context-param>
      
       <context-param>
      
       <param-name>com.sun.faces.validateXml</param-name>
      
       <param-value>true</param-value>
      
       </context-param>
      
       <context-param>
      
       <param-name>com.sun.faces.verifyObjects</param-name>
      
       <param-value>true</param-value>
      
       </context-param>
      
       <context-param>
      
       <param-name>org.richfaces.SKIN</param-name>
      
       <param-value>DEFAULT</param-value>
      
       </context-param>
      
      
      
       <servlet>
      
       <servlet-name>Faces Servlet</servlet-name>
      
       <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
      
       <load-on-startup>1</load-on-startup>
      
       </servlet>
      
      
      
       <!-- Faces Servlet Mapping -->
      
       <servlet-mapping>
      
       <servlet-name>Faces Servlet</servlet-name>
      
       <url-pattern>*.seam</url-pattern>
      
       </servlet-mapping>
      
      
      
       <!-- MyFaces -->
      
       <listener>
      
       <listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>
      
       </listener>
      
      </web-app>


      When I use the above config, I get a classnotfound for the

      <listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>


      The reason for this being... For Seam to work with JBoss 4.2, the myfaces jars need to be replaced with Sun's JSF RI jars.

      Is there any example for a Seam/Richfaces integration to work in a JBoss 4.2.1/ Seam 2.0/facelets environment. I am specifically looking for the web.xml/faces-config.xml and other config files that are needed.

      Thanks in advance.