tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daryl Stultz <>
Subject DefaultServlet subclass behavior change TC6 to 8
Date Wed, 25 Apr 2018 20:08:35 GMT

We are upgrading from Tomcat 6 to Tomcat 8.5. We have a servlet that extends org.apache.catalina.servlets.DefaultServlet.
We override getRelativePath(HttpServletRequest request), that's all.

The purpose of this servlet is to do a sort of redirect, the browser asks for a spreadsheet
"my-site.css" which is mapped to our servlet. In getRelativePath we return "my-site-prod.css"
or "my-site-test.css" for example depending on the environment the application is running

If I override doGet (calling super) I can see that doGet is called but getRelativePath is
never called and the browser gets a 404 error for "my-site.css".

Anyone know what I need to change to restore the behavior as it was in Tomcat 6? I'm afraid
I inherited this code so it's hard to say why it was done this way.



Daryl Stultz
Principal Software Developer
OpenTempo, Inc<><>

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message