You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Fred Toth <ft...@synernet.com> on 2008/04/24 05:31:36 UTC
Extending DefaultServlet, broken welcome-file
Hi all,
I'm lost in the woods.
Some time ago we built an application that required us to extend
the TC 5.5 DefaultServlet. All we did was point it to an external path
(outside the war file). It works great.
However, I now realize that I've somehow broken the <welcome-file>
mechanism for our extended servlet.
I've been churning through the source trying to find where the
<welcome-file>
stuff is implemented. I can see that the configuration is loaded into
the context,
but for the life of me I can't see how the DefaultServlet uses that
information.
I keep looking for something like:
if (isDirectory)
if there's a welcome file
serve the welcome file
But no luck. Perhaps this is buried in the ProxyDirContext that
abstracts the
actual file system resources?
Again, I'm lost. Can anyone shed light on this?
Thanks,
Fred
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: Extending DefaultServlet, broken welcome-file
Posted by Tim Funk <fu...@joedog.org>.
You need to look at org.apache.tomcat.util.http.mapper.Mapper
Welcome files belong to the container since jsp's can be used as welcome
files and jsps are satisfied by a different servlet.
-Tim
Fred Toth wrote:
> Hi all,
>
> I'm lost in the woods.
>
> Some time ago we built an application that required us to extend
> the TC 5.5 DefaultServlet. All we did was point it to an external path
> (outside the war file). It works great.
>
> However, I now realize that I've somehow broken the <welcome-file>
> mechanism for our extended servlet.
>
> I've been churning through the source trying to find where the
> <welcome-file>
> stuff is implemented. I can see that the configuration is loaded into
> the context,
> but for the life of me I can't see how the DefaultServlet uses that
> information.
>
> I keep looking for something like:
>
> if (isDirectory)
> if there's a welcome file
> serve the welcome file
>
> But no luck. Perhaps this is buried in the ProxyDirContext that
> abstracts the
> actual file system resources?
>
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org