Nance, Michael wrote:
> One other thing I DO NOT have a /buy dir under webapps
See below.
[...]
> requesting either http://localhost:8080/buy/MLBEventInfo or
> http://localhost/buy/MLBEventInfo
> gives me the same result I get a 404 /buy/MLBEventInfo not found
>
> This is from servlet.xml
>
> <servlet>
> <servlet-name>
> MLBEventInfo
> </servlet-name>
> <servlet-class>
> com.tickets.presentation.mlb.MLBEventInfo
> </servlet-class>
> </servlet>
I don't know what servlet.xml is!? The above should be in
web.xml (see below). Since "buy" is not under webapps, you
will need something like this in server.xml (not servlet.xml):
<!-- Add a special context for buy since it's not in
the webapps directory.
-->
<Context path="/buy"
docBase="SOMEWHERE/buy"
debug="0"
reloadable="true">
</Context>
Change SOMEWHERE/buy to the full path to "buy".
> And this is in my web.xml
>
> <servlet-name>
> invoker
> </servlet-name>
> <url-pattern>
> /buy/*
> </url-pattern>
> </servlet-mapping>
This isn't going to work the way you expect. You need
something like:
<servlet>
<servlet-name>
MLBEventInfoServlet
</servlet-name>
<servlet-name>
com.tickets.presentation.mlb.MLBEventInfo
</servlet-name>
</servlet>
<servlet-mapping>
<servlet-name>
MLBEventInfoServlet
</servlet-name>
<url-pattern>
MLBEventInfo
</url-pattern>
<servlet-mapping>
Now when you go to http://localhost:8080/buy/MLBEventInfo
it divides the URL up into:
http://localhost:8080 + /buy + /MLBEventInfo
^ context ^ servlet
> <servlet-mapping>
> <servlet-name>
> invoker
> </servlet-name>
> <url-pattern>
> /olympics/*
> </url-pattern>
> </servlet-mapping>
> <servlet-mapping>
> <servlet-name>
> jsp
> </servlet-name>
> <url-pattern>
> *.jsp
> </url-pattern>
> </servlet-mapping>
>
>
> These come from a working JSErv Config (we are converting
> form JSErv to Mod
> JK)
I'm afraid I do not have experience with JServ, maybe others
can help you with a more straight forward approach to
converting. The example I've given will only work for /buy and
not for /olympics, etc.
I suggest that you read both Tomcat - A Minimalistic User's Guide
and Developing Applications With Tomcat:
http://jakarta.apache.org/tomcat/tomcat-3.2-doc/uguide/tomcat_ug.html
http://jakarta.apache.org/tomcat/tomcat-3.2-doc/appdev/index.html
-- Andrew