You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Alistair Young <al...@gmail.com> on 2008/01/11 18:54:25 UTC
Tomcat configuration: restricted set of handled file types
Hi,
I've recently signed up with a third-party web hosting outfit who support
Tomcat. However, I've been having a few difficulties and would like to
understand better what is going on before I contact their technical support
again!
I have a very simple web application, with a servlet configured (in web.xml)
to handle .jspx files. When I deploy the application to a local Tomcat
server (5.5), everything is fine. However, when deployed on the hosted
service, visiting my Test/test.jspx page simply dumped out the source of the
.jspx file.
So, I queried this with their technical support and they said "ah, our
server doesn't understand .jspx - they need to be .jsp files". So, I
renamed my test.jspx file to test.jsp and updated web.xml accordingly. And,
sure enough, when I deployed this my servlet triggered and the page was
displayed correctly.
However, the framework my little application is using (ICEfaces), relies on
the ability for other (non .jsp) files to trigger the servlet. For example,
the markup which is generated by my test.jsp page includes reference to a
couple of .js files which are generated by the servlet. In web.xml, things
are set up so that everything beneath a particular directory will be handled
by the servlet - but this evidently is not triggering on my hosted service.
So, my question is this: can somebody point me to the appropriate Tomcat
settings which are causing this? It seems that only certain file extensions
are being handled by Tomcat, regardless of what is in a particular
application's web.xml. (But note that for those accepted extensions - e.g.
.jsp - I appear able to override the servlet, and hence my web.xml _is_
being honoured - at least in part).
Armed with this, I'm hopeful that I can make some useful suggestions to
their tech support team, and perhaps get things working in the way I hoped
they would.
Thanks all,
Alistair.
RE: Tomcat configuration: restricted set of handled file types
Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Alistair Young [mailto:alistair.j.young@gmail.com]
> Subject: Tomcat configuration: restricted set of handled file types
>
> I queried this with their technical support and they said "ah, our
> server doesn't understand .jspx - they need to be .jsp files".
Ask them what version of Tomcat they're running. For 5.5, the jsp
servlet uses these mappings:
<servlet-mapping>
<servlet-name>jsp</servlet-name>
<url-pattern>*.jsp</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>jsp</servlet-name>
<url-pattern>*.jspx</url-pattern>
</servlet-mapping>
If they've changed this, what's their justification for doing so?
- Chuck
THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.
---------------------------------------------------------------------
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