aspose file tools
The moose likes JSF and the fly likes javax.servlet.ServletException: PWC1232: Exceeded maximum depth for nested request dispatches: 20 Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » JSF
Reply Bookmark "javax.servlet.ServletException: PWC1232: Exceeded maximum depth for nested request dispatches: 20" Watch "javax.servlet.ServletException: PWC1232: Exceeded maximum depth for nested request dispatches: 20" New topic
Author

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

Volodymyr Levytskyi
Ranch Hand

Joined: Mar 29, 2012
Posts: 187

Hello!

I decided to move to *.jsf mapping for FacesServlet and as a result I can't anyway resolve this error:


I have everywhere in my webapp .jsf ending instead of .xhtml. My files have extension .xhtml but I access them using .jsf.
I have searched the Internet and I can't find solution for me to work!
My mapping is :
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 14456
    
    7

I can't really tell, but I suspect that you either have a configuration problem in PrettyFaces or your PrettyFaces URLs are malformed.

When I run into stuff like this, I usually end up having to set debugger breakpoints and look at the URLs running through the filters. Which, 2 days later leads me to discover I misplaced a comma or something.


Customer surveys are for companies who didn't pay proper attention to begin with.
Volodymyr Levytskyi
Ranch Hand

Joined: Mar 29, 2012
Posts: 187

Hello!

This error went away after I removed the following context-param from web.xml:

Unfirtunately instead I have new problem. Browser does not render styled page but only XML tree of jsf elements like in source xhtml file.
Google chrome prints above XML tree:
This XML file does not appear to have any style information associated with it. The document tree is shown below.

I found that it can be caused that page is not intercepted by FacesServlet but it is impossible as I call /forums.jsf when FacesServlet is mapped to:

It is not the problem with charset too. Because I try with both UTF-8 and ISO-8859-1. They both fail.

Does anybody know why XML tree is rendered instead of styled web page?

Thank you!
Volodymyr Levytskyi
Ranch Hand

Joined: Mar 29, 2012
Posts: 187

Finally I think the best is to move to old .xhtml mapping for FacesServlet.

In my stacktrace from first post there is really JSP view handler:



It seems from this thread http://stackoverflow.com/questions/2000436/stackoverflow-when-running-jsf

that .jsf mapping for FacesServlet is intercepted by Jsp ViewHandler. Probably it causes the loop and XML tree.

Don't you think that it is best to use .xhtml mapping for FacesServlet?
Volodymyr Levytskyi
Ranch Hand

Joined: Mar 29, 2012
Posts: 187

Ha ha ha!

I myself disabled jsf facelet view handler by this context-param in web.xml:



I removed this !
FacesServlet mapping *.jsf is OK !!!
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: javax.servlet.ServletException: PWC1232: Exceeded maximum depth for nested request dispatches: 20
 
Similar Threads
Exceeded maximum depth for nested request
JSF Installation problem
Casting Exception
java.lang.NullPointerException at com.sun.faces.context.flash.ELFlash.loggingGetPhaseMapForWriting
Managed bean