tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <>
Subject Re: Tomcat 7 - New attribut aliases in the context configuration item
Date Fri, 02 Dec 2011 20:14:26 GMT
Hash: SHA1


On 11/30/11 8:58 AM, Sylvain Goulmy wrote:
> These directories are defined as "extension" of my application and
> another important thing is that i can also extend files which are
> at the root of my application (as index.html).

What does it mean to "extend" an existing file? Replace it or do some
kind of horrendous merge?

> After a few more test with Tomcat i understand that :
> - You cannot "extend" directory, if you define an external location
> which math an existing directory of your application, the
> ressources of your application become unreachable.

That sounds about right.

> - As the documentation say "Using '/' as an aliasPath is not
> allowed.", you cannot extend any ressource which is at the root of
> your application.

Right: if you alias /, you are essentially deploying another webapp --
so you should just do that instead.

Tomcat's alias mechanism is intended for use in the case where you
have a bunch of static content in a separate directory and you just
want to be able to serve it through the same webapp without actually
deploying two separate contexts. That's why it works the way it does.

You might be able to build this capability yourself by writing your
own DirContext and specifying it with a <Resources> element within
your <Context> element. See for details.

- -chris
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Comment: GPGTools -
Comment: Using GnuPG with Mozilla -


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message