- This topic has 8 replies, 4 voices, and was last updated 20 years, 5 months ago by
Scott Anderson.
-
AuthorPosts
-
GrahamJohnsonMemberIs there any way to suppress the display of the “Unhandled exception type …” error indicators in JSPs that have a <%@ page errorPage=”…” %> directive? I don’t consider these exceptions unhandled, since the error page handles them.
Also, is there any way to get a list view of all the error indicators? I can’t find any, and it is annoying to only be able to see the problems by mousing over each tiny indicator individually. Non-problematics “errors” (the unhandled exception errors) are mixed in with real errors, and it seems there is no easy way to tell that any of the errors are ones I am interested in.
Riyad KallaMemberGraham,
If you are getting this error marker incorrectly can you post a sample JSP page here for me to test? If its a bug we would like to correct it.You can try turning off JSP validation if the erorrs you are seeing ar marked in the LEFT margin (compiler errors), but if they are in the RIGHT margin (reconciler errors) then that is the JSP Editor’s reconciler at work and is a different animal. Those errors will not be displayed in a list, which follows the Java Editor style as well (reconciler errors are not shown in the problem view).
GrahamJohnsonMemberThe exceptions technically are unhandled (in the sense that they are not caught), but the existence of the errorPage directive keeps this from being an error — the JSP compiles and works as desired, forwarding to the error page when the uncaught exceptions occur.
I guess this is a feature request — there should be a way to tell the reconciler to not display unhandled exceptions in JSPs with errorPage directives.
Riyad KallaMemberLet me pass this along and see what our dev has to say…
Riyad KallaMemberGraham it turns out we have this bug already filed (discrepencies between validation and reconciler) and its a royal PIA to solve, most likely won’t get done soon… part of the reasons is that we use Jasper2 from Tomcat to compile/validate the JSP pages, however the WTP editors use the internal JSP reconciler from IBM which are most likely using validation logic from Websphere, so its a bit of a he-said-she-said game here… as Tomcat says this page is fine, but it would most likely not run in Websphere.
peteclark3MemberSo there is no way to simply suppress it?
Scott AndersonParticipantAdding a catch block will certainly suppress it in the short term. In the longer term, the bug Riyad mentioned is scheduled to be resolved in 3.8.3 in December.
peteclark3MemberWouldn’t a catch block override my errorpage settings in my web.xml?[/code]
Scott AndersonParticipantI believe error pages are typically intended for instances of RuntimeException or Error, since exceptions of those types would typically be completely unexpected. However declared exceptions are generally caught. If you then don’t want to handle it, you can always rethrow it as a RuntimeException or Error to invoke your error page.
-
AuthorPosts