Pessoal estou tentando achar algum tópico ou tutorial para fazer uma página de erro 4004. Ou seja quando a pessoa tentar digitar algo após a barra do site e a página não existe eu quero redireciona-la para uma página de erro que eu fiz. Alguém sabe com faço isso ?
Fiz o seguinte mapeamento no Web Xml, mas mesmo assim não funcionou.. falta mais alguma coisa nesse meu XML?
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" id="WebApp_ID" version="3.0">
<display-name>ProjetoWEB</display-name>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.html</welcome-file>
<welcome-file>default.htm</welcome-file>
<welcome-file>default.jsp</welcome-file>
</welcome-file-list>
<error-page>
<error-code>404</error-code>
<location>/erros/erro.jsp</location>
</error-page>
</web-app>