Tag Archives: happygiraffe

Mapping a servlet to /

An interesting problem cropped up today. We want to use a servlet for the home page in a Spring Web MVC project. Initially we had this in web.xml.

<servlet>
<servlet-name>foo</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>foo</servlet-name>
[...]

Tomcat Logging in WTP

I’ve just been trying to enable debug logging for tomcat (don’t ask). Normally you do this by editing $CATALINA_HOME/conf/logging.properties and restarting.
Except I tried that in Eclipse (using WTP) and it didn’t work.
I tried copying it to the $CATALINA_BASE/conf directory instead1.
Still no joy.
I’ve just found the answer, after looking in the tomcat source. It [...]