Hi, for some reason the code below always outputs the catch-all errorPage.jsp when it should output arithmeticException.jsp b/c I do ${10/0}. Can anyone see my error?
Thanks so much, Carmen.
<html><body> About to be bad... <% int x = 10/0; %> </body></html>
Tested Using Tomcat 5.5.7. Show the error page releted to Throwable. But it the <exception-type>java.lang.Throwable </exception-type> removed form web.xml,show the page related to Arithmetic Exception.
Working perfectly with Sun Java System Application Server 8.1, with both entries. Properly shows the page related to ArithmeticException.
So does this mean that the order in which exceptions are handled is container specific
The order is not important for any container. It is problem of supertype and sub-type of Exceptions. The above results are same for any order entries for <error-page>
From what i understand is the behaviour is different for different containers. What should be the answer when confronted with such a question at the actual exam?