I was going thru the web application; logged off (session is expired) and using browser Back button i somehow came to a an URL and pressed enter and surprising this jsp page was not called when a NullPointerException happened, and in the browser i have a page showing HTTP 500 , internal Server error ???
So should i also add
to web.xml to handle this?? I will also test by adding this HTTP err code and see where it goes..
Your ideas on this; Appreciate your help; Thanks again
PS: How do you guys do error handling and what is the best way.. [ December 16, 2005: Message edited by: Bear Bibeault ]
you will have to add different <error-page> tags for different type of errors (500,404 ..etc).
and the error-page in your web.xml handles the situations when there is an exception only (from your application code).
And moreover when you said you clicked the browser's back button and then clicked enter, you got null pointer exception.. that might not be actually a null pointer exception ... since the session has expired, it could not redirect you to the next page which is not due to any exception generated.
and you can aswell display different pages for different types of errors.