I am using a login filter with Facelets and JSF 2.0 that is giving me a blank page when an error is generated by business logic. When I take the filter off, the error page is shown properly. It is happening on a request (rather than a forward). It worked in JSF 1.2 with JSPs. Any ideas what I might be doing wrong?
Here's the filter mapping from my web.xml.
Here's my error-page definitions in my web.xml:
My actual error page is called /pages/error.xhtml. The error is happening on a call to chain.doFilter() in the Filter. Is there a good way to see what page the filter might be trying to load on the error? Any other tips to debug?
Depending on the server, attempts to generate JSF-based error pages may not work. In order for JSF to behave properly, you have to route a URL through the FacesServlet, and the container may not be fully simulating this process when it dispatches the error page. For best results, keep pages referenced from web.xml as straight JSP or HTML files. They can forward to JSF, if the situation permits it.
Bjoke: A "Bully Joke". A Statement or action made with malicious intent - unless challenged. At which point it magically transforms into "I was just funnin'" or "What's the matter, can't take a joke?"
I tried using a JSP page for my error page but got the same blank page when the business logic threw an error and the login filter was turned on. Any other ideas to try? I am using Apache Tomcat 6 if that matters.
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop