webtier@glassfish.java.net

Help with PWC1232: Exceeded maximum depth for nested request dispatches

From: <webtier_at_javadesktop.org>
Date: Tue, 04 May 2010 04:35:22 PDT

I'm trying to get a simple JSF 2.0 page to show using Glassfish V3 but I keep getting the following exception:

javax.servlet.ServletException: PWC1232: Exceeded maximum depth for nested request dispatches: 20

Here's my page index.xhtml under WebContent:

[code]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
          "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
        xmlns:h="http://java.sun.com/jsf/html">
<head>
<title>Title</title>
<link type="text/css" href="css/styles.css" rel="stylesheet" />
</head>
 
<body>
        <h:form>
                <h:outputText id="message" value="Hello World!"/>
        </h:form>
</body>
 
</html>
[/code]

and here is my web.xml:

[code]
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" id="WebApp_ID" version="2.5">
  <display-name>mohrts-web</display-name>
  <welcome-file-list>
    <welcome-file>index.xhtml</welcome-file>
  </welcome-file-list>
  <servlet>
    <servlet-name>Faces Servlet</servlet-name>
    <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
    <load-on-startup>1</load-on-startup>
  </servlet>
  <servlet-mapping>
    <servlet-name>Faces Servlet</servlet-name>
    <url-pattern>*.xhtml</url-pattern>
  </servlet-mapping>
  <context-param>
    <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
    <param-value>server</param-value>
  </context-param>
</web-app>
[/code]

From what I can find on google, it looks like the page is recursively trying to render itself and I have no idea why. I'm telling it to pass .xhtml pages through the Faces Servlet so I don't know why it would get stuck there. Any help would be appreciated. Thanks.
[Message sent by forum member 'cain05']

http://forums.java.net/jive/thread.jspa?messageID=400313