2

On our DXA website (1.5, java version) we are running against the following problem: All 404 exceptions get caught without any problem by the Page Controller in the handleNotFoundException method except when it has a .jsp extension. When we type in a url with a .jsp extension the default Tomcat 404 page is shown. This is a major issue since the previous version of that website had .jsp pages and we want old links to at least be rendered in a clean 404 page.

Is there any way we can change this behaviour?

Kr,

Thomas

3

change the mapping of the jsp servlet to /WEB-INF/Views/* so that the JSP servlet is only used for views, and leaves all other requests for the dispatcher servlet.

update the web.xml on webapp level

    <servlet-mapping>
    <servlet-name>jsp</servlet-name>
    <url-pattern>/WEB-INF/Views/</url-pattern>*
</servlet-mapping>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.