Why the default error page is not shown even after custom page is defined in JBoss Seam pages.xml?

Solution Verified - Updated -


When an invalid request parameter is specified on a Seam page, the resulting exception does not redirect to the custom error page. The standard page HTTP Status 500 Exception report is shown. Here is an example of URL:


Note: other exceptions are correctly redirected to the custom error page. The invalid request param is the only case where it uses the default error page. The stack trace in the logs is:

2012-04-10 17:21:45,170   ERROR [[Faces Servlet]] Servlet.service() for servlet Faces Servlet threw exception
java.lang.IllegalArgumentException: URLDecoder: Illegal hex characters in escape (%) pattern - For input string: "%2"
    at <a class="make_room_for_kcs" href="http://java.net" target="_blank">java.net</a>.URLDecoder.decode(URLDecoder.java:173)
    at org.ajax4jsf.webapp.BaseFilter.parseQueryString(BaseFilter.java:210)
    at org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(BaseFilter.java:325)
    at org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:500)
    at org.jboss.seam.web.Ajax4jsfFilter.doFilter(Ajax4jsfFilter.java:56)
    at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
    at org.jboss.seam.web.LoggingFilter.doFilter(LoggingFilter.java:60)
    at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
    at org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:158)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

Also, the following message appears in server.log:

2012-04-11 11:56:55,246   ERROR [[localhost]] Exception Processing ErrorPage[errorCode=500, location=/error.page]

Below is the pages.xml configuration:

   <redirect view-id="/error.xhtml">
      <message severity="error">Unexpected error, please try again</message>


  • JBoss Enterprise Application Platform 5.x
  • JBoss Web Framework Kit all versions

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content