web.xml fragment
<!-- Handles all requests into the application -->
<servlet>
<servlet-name>Spring MVC Dispatcher Servlet</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<init-param>
<param-name>contextConfigLocation</param-name>
<param-value>/WEB-INF/spring/app-config.xml</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>Spring MVC Dispatcher Servlet</servlet-name>
<url-pattern>/*</url-pattern>
</servlet-mapping>
It works fine but I'd like to NOT let the Dispatcher Servlet handle *.html requests. How do I I do that? Thanks.
In Spring MVC 3.x there is the default servlet handler to take care of this problem.
just add this to the Spring XML config:
<mvc:default-servlet-handler/>