tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jochen Wiedmann <>
Subject [Patch] TC3.2: error-page directive is not properly supported by Jasper
Date Mon, 03 Sep 2001 09:01:54 GMT


I have just submitted #3377 to Bugzilla, where I
describe the following problem and a workaround.

When using the error-page directive in web.xml, the
exception handling of JSP pages is insufficient. What
happens is that Jasper catches the exception, but isn't
aware of the configured error-page. As it may throw
only ServletExceptions, it does exactly that, discards
the actual exception, keeps the exception message and
creates a new ServletException. (See handlePageException().)

In practice that means, that the stack trace is lost in
error messages, making them practically useless, because
you always see the stack trace of handlePageException().

IMO Jasper should have a possibility to see the error-page
directive and handle it properly. In our production environment
we do this with the attached patch, which is mainly a
workaround, because it breaks the separation between
TomCat and Jasper. However, as the Specification does not
give a way to find the configured error-page (at least no
way that I can think of), this is probably the way to



View raw message