Currently, we are deploying an AngularJS webapp using a tomcat servlet. that uses a standard Web Application deployment descriptor, web.xml located in the WEB-INF directory. The webapp directly handles URL mapping and error codes internally, so we would not like to have 404 error code when a resource is not found (Specially REST resources).
We have been able to but being able to get rid of the error changing 404 to 200, stills this solution does not convince me 100%.
(Normal use of error-page)
<error-page>
<error-code>404</error-code>
<location>/404.html</location>
</error-page>
(Is this solution ok?)
<error-page>
<!--Every time 200 is used as error code we stray further from God's Light.-->
<error-code>200</error-code>
<location>/404.html</location>
</error-page>
Is this solution the most appropriate or there is something we are missing?
