myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Laurent Cottereau <laur...@cottereau.name>
Subject Exception doesn't get redirected to error-page when myfaces.ERROR_HANDLING is set to false
Date Mon, 22 Apr 2013 14:12:51 GMT
Hello everyone. This question was also posted on
http://stackoverflow.com/questions/16149292/exception-doesnt-get-redirected-to-error-page-when-myfaces-error-handling-is-se

I have implemented an error JSF page which gives basic information to
users. It is triggered by the <error-page> tag in my web.xml

<error-page>
    <location>/error</location></error-page>

This works fine with a 404 error. In order to use it also for exceptions, I
have disabled error handling by MyFaces 2.1.10 in web.xml

<context-param>
    <param-name>org.apache.myfaces.ERROR_HANDLING</param-name>
    <param-value>false</param-value></context-param>

In
https://cwiki.apache.org/confluence/display/MYFACES/Handling+Server+Errors#HandlingServerErrors-Provideanerrorpageit
says that an Exception should trigger a redirection to
/error. However, when I throw a RuntimeException in my code, it shows in
the logs but all the user gets is a blank page.

I can't seem to figure out why and how to get (if possible) the expected
behaviour.

The application server is tomcat-7.0.35
Any idea ? Thank you in advance for your help

--
  Laurent Cottereau
  laurent@cottereau.name
  http://laurent.cottereau.name

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message