tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Parsons Technical Services" <parsonstechni...@earthlink.net>
Subject Re: [Newbie] Failed access to servlet via URL mapping (context setting problem?)
Date Mon, 17 Jan 2005 05:35:50 GMT

> I didn't do any setting up, other than to install the compatibility
> patch as directed.  It is my understanding that this acts as a bridge
> between the "new" V5.5 tomcat architecture, and the old 1.4 JDK.  From
> the success of the trial servlets, the installation seems to be
> working, and I just suspect that I have failed to configure something
> properly.


Ok. Just wanted to be sure as this has been the issue on several posts 
lately.

Now for your problem. There are two (or more) ways that you can deploy an 
application. One is by manual file and folder creation and the other is by 
WAR files. Either way there is a directory structure that needs to be 
followed.

>From a recent post:

Quote"
Hi,

I think it would be good practice to require your developers to create
war file for you.

http://java.sun.com/blueprints/guidelines/designing_enterprise_applications_2e/technologies/technologies3.html#1043856

Anyway, there is some links that might be useful

http://java.sun.com/j2se/1.4.2/docs/tooldocs/tools.html#basic
look jar-tool, war file is same format that war file.

I think you should read also servlet spefication specks
http://jcp.org/aboutJava/communityprocess/final/jsr154/index.html

And maybe it would be worth of use tools like ant
http://ant.apache.org/

- Jukka -

" Unquote

This should get you the information on the structure you need to set up. 
>From there you need to create a context.xml file that will solve your 
problem. In 5.5 you do not use the path field unless you put the context in 
the server.xml.

http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/context.html
gives you several locations to place the context files. If you are not using 
WAR files, then use the "appname".xml

per the above page place it in the 
$CATALINA_HOME/conf/[enginename]/[hostname]/ directory
The path is then taken from the name of the xml file.
OR
context.xml and place it in /META-INF/context.xml inside the application 
files  and the path will be based on the docBase.

If you look there now you will find some files for the built in apps (I 
think) I do not run 5.5 but 5.0 and there are some changes as to what was 
included.

Unless you want it to be the default app, that's in last weeks archives.

Doug 



---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message