You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by David Teare <da...@yahoo.com> on 2003/05/13 21:14:20 UTC
Unhandled Exceptions [use error-page in web.xml?]
Hi all,
How do I catch and handle exceptions generated by
struts?
For instance, during development, it is common to try
to forward to a jsp/action that is missing from
struts-config.xml (typo, etc.). Currently when this
happens, I find myself looking at a blank page in the
browser and no logs in my log4j file nor stdout/stderr
and then spending a great deal of time debugging.
I have tried using global exceptions in
struts-config.xml, but for some reason the error page
never comes up (perhaps struts doesn't throw an
exception in this case). In fact, when an action
throws a RuntimeException, I find the exception object
in the JSP null!
How does one normally configure the app such that all
exceptions are eventually logged and something nice
displayed to the user? I tried using the error-page
properties in web.xml, but to no avail since I don't
think struts is throwing exceptions in all cases like
this.
Thanks!
--Dave.
__________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
http://search.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org