When the error page comes from Apache, you can replace it using an alternate error page specified in the Apache config file (httpd.conf) -- see the ErrorDocument directive.
I'd expect the web.xml file to have equivalent options on the
Tomcat side, but I'd have to read the spec.
The secret of how to be miserable is to constantly expect things are going to happen the way that they are "supposed" to happen.
You can have faith, which carries the understanding that you may be disappointed. Then there's being a willfully-blind idiot, which virtually guarantees it.