S
subscriptions
Hi,
I'm putting together a JSP/Servlet webapp for shortening URLs. It
works fine if I install it as a sub-directory of my domain for instance
"example.com/linker." But I need it to be the root webapp for my
domain; when I do this, however, I get a directory listing instead. I
get the listing whether or not I go through connectors, thus
"example.com:8080" also shows the listing, but
"example.com:8080/linker" does not.
I don't have a welcome-file, nor do I have a catch-all servlet mapping.
What I do have is a catch-all filter-mapping, thus:
<filter-mapping>
<filter-name>ControllerFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
The ControllerFilter then links to the required resource, be it local
or remote. Here are all the servlet filters that I use:
<servlet-mapping>
<servlet-name>MainPage</servlet-name>
<url-pattern>/start</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>ErrorPage</servlet-name>
<url-pattern>/error</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>SubmitLinkServlet</servlet-name>
<url-pattern>/submitLink</url-pattern>
</servlet-mapping>
I'm linking from Apache to Tomcat 5.5 via ajp13/mod_jk2. The Host
entry in my server.xml file looks like this:
<Host name="example.com" appBase="/usr/local/tomcat/webapps.other">
<Context path="" docBase="linker" debug="0"/>
</Host>
with the webapp being at "/usr/local/tomcat/webapps.other/linker."
Any ideas?
Thanks,
Walter Gildersleeve
Freiburg, Germany
Here are links to the actual on-line application:
http://linkfrog.net (should work, doesn't though)
http://linkfrog.net:8080 (doesn't work either)
http://linkfrog.net/linker (works)
http://linkfrog.net:8080/linker (also works)
I'm putting together a JSP/Servlet webapp for shortening URLs. It
works fine if I install it as a sub-directory of my domain for instance
"example.com/linker." But I need it to be the root webapp for my
domain; when I do this, however, I get a directory listing instead. I
get the listing whether or not I go through connectors, thus
"example.com:8080" also shows the listing, but
"example.com:8080/linker" does not.
I don't have a welcome-file, nor do I have a catch-all servlet mapping.
What I do have is a catch-all filter-mapping, thus:
<filter-mapping>
<filter-name>ControllerFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
The ControllerFilter then links to the required resource, be it local
or remote. Here are all the servlet filters that I use:
<servlet-mapping>
<servlet-name>MainPage</servlet-name>
<url-pattern>/start</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>ErrorPage</servlet-name>
<url-pattern>/error</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>SubmitLinkServlet</servlet-name>
<url-pattern>/submitLink</url-pattern>
</servlet-mapping>
I'm linking from Apache to Tomcat 5.5 via ajp13/mod_jk2. The Host
entry in my server.xml file looks like this:
<Host name="example.com" appBase="/usr/local/tomcat/webapps.other">
<Context path="" docBase="linker" debug="0"/>
</Host>
with the webapp being at "/usr/local/tomcat/webapps.other/linker."
Any ideas?
Thanks,
Walter Gildersleeve
Freiburg, Germany
Here are links to the actual on-line application:
http://linkfrog.net (should work, doesn't though)
http://linkfrog.net:8080 (doesn't work either)
http://linkfrog.net/linker (works)
http://linkfrog.net:8080/linker (also works)