This week's giveaway is in the Java/Jakarta EE forum.
We're giving away four copies of Java EE 8 High Performance and have Romain Manni-Bucau on-line!
See welcome thread
Win a copy of Java EE 8 High Performance this week in the Java/Jakarta EE forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Servlet URL Aliasing (Apache + TomCat)  RSS feed

Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here's a problem I've found some references too, but no conclusive answer:
I would like to have my Apache webserver forward specific requests to TomCat, not neccesarily throurgh the standard /servlet mapping.
In essence I would like
to behave the same as
I know (and succeeded) in doing this through:

in the Apache cofiguration (using mod_jk), which, in combination with

In the web.xml file.
BUT, and here's the catch, suppose I want to do:
(this could be *really* good for hiding your implementation from users, as well as other nifty path-related advantages), the setup does not work.
I've tried

but this will not get passed on to the servlet, instead, TomCat tries to retrieve the file (resulting in a 404)...
Maybe URL rewriting (using mod_rewrite) would work, but that's a complete mystery to me.
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!