You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Stefán Freyr Stefánsson <st...@decode.is> on 2000/04/14 18:32:12 UTC
Web applications and stuff
Hello. I'm new to Tomcat and all this so I'm not really sure if I'm in the
right place to ask my question... I just hope I am.
The thing is that I'm having trouble finding documentation about Tomcat
(surprise, surprise). I'm trying to make a new web-application for my
project and it's not going too good. I posted a message on the
comp.lang.java.programmer newsgroup but I haven't received anything from
there so I'm gonna try to send it to this mailin list instead... and hope it
works.
Here's my post to comp.lang.java.programmer:
Hi!
I'm trying to set up Apache + Tomcat on my Windows NT 4.0 (Workstation)
platform. This is not going too good to say the least.
I've managed to get the two applications up and running (finally) and the
examples ("http://localhost/examples/servlets/"
and "http://localhost/examples/jsp/") work just fine.
However...
I want to put up a project of my own which would then run
in "http://localhost/myproject/" (or something like that). I've tried to
follow the
instructions in the "faq" file that came with Tomcat and that doesn't work
(I read somewhere that one of the two ways given in the "faq" file don't
work so I used the other one... the one that's supposed to work... well..
actually I used both ways). I have no idea what I'm doing wrong here but it
whatever it is it must be something big!
One thing about that "faq" file. It has a question about exactly what I
want to do ("Q: What is a web-application? How can I install a new
web-application?") but it just doesn't seem to work... it seems like
something more has to be done. So I have a few questions that came into my
mind:
1) It says that I should use a <servlet> element in the web.xml file to
register a servlet. Can someone tell me how that tag is constructed? I mean
what do all the "sub-tags" mean? It also says that I should put the classes
in the "classes" folder which is stored in the "WEB-INF" folder. What about
packages? Do I need to construct my package structure within the "classes"
folder so if I'm
using "packagename.ClassName" should I make a "packagename" folder inside
the "classes" folder and then put my "ClassName" class file in there?
2) What is a WAR file? I'm seeing this thing all over the place and the
sample thing the "faq" file told me to put in the "server.xml" file (to make
my own web-application) looks like this:
<Context path="/baseball" docBase="baseball"
defaultSessionTimeOut="30" isWARExpanded="true" isWARValidated="false"
isInvokerEnabled="true" isWorkDirPersistent="false"/>
OK! That's it! "isWARExpanded="true""??? What is that? I'm guessing
since my context (which I'm again guessing is the same as a web- application
in a sense) is WAR expanded then I should probably have a WAR file to go
with it right? Ok... then tell me how to make that WAR file!
Arrrghhh... only problem with open source is that nobody feels like doing
the proper documentation for it!
If anyone can help me by pointing out some "real" step-by-step instructions
(that actually work) it would be very much appreciated. Or even if someone
who has had experience with this would be so kind as to let me contact
him/her with questions about this that would be awsome.
Kind regards from Iceland
Stefan
UPDATE: I just found some more docs that came with the Tomcat (html
format). It explains something about what I was asking about (like WAR
files and such) but nothing that can really be of any use to me. It doesn't
say HOW to make the war file, what it actually does and so on.
Any help would be greatly appreciated. Thank you
Stefan
Re: Web applications and stuff
Posted by Phil Welch <Ph...@worldnet.att.net>.
Stefan,
Try:
http://jakarta.apache.org/cvsweb/index.cgi/~checkout~/jakarta-tomcat/src/doc
/uguide/tomcat_ug.html?content-type=text/plain&only_with_tag=HEAD
as a good place to start.
Phil Welch
----- Original Message -----
From: "Stefán Freyr Stefánsson" <st...@decode.is>
To: <to...@jakarta.apache.org>
Sent: Friday, April 14, 2000 11:32 AM
Subject: Web applications and stuff
> Hello. I'm new to Tomcat and all this so I'm not really sure if I'm in
the
> right place to ask my question... I just hope I am.
>
> The thing is that I'm having trouble finding documentation about Tomcat
> (surprise, surprise). I'm trying to make a new web-application for my
> project and it's not going too good. I posted a message on the
> comp.lang.java.programmer newsgroup but I haven't received anything from
> there so I'm gonna try to send it to this mailin list instead... and hope
it
> works.
>
> Here's my post to comp.lang.java.programmer:
>
> Hi!
>
> I'm trying to set up Apache + Tomcat on my Windows NT 4.0 (Workstation)
> platform. This is not going too good to say the least.
>
> I've managed to get the two applications up and running (finally) and the
> examples ("http://localhost/examples/servlets/"
> and "http://localhost/examples/jsp/") work just fine.
>
> However...
>
> I want to put up a project of my own which would then run
> in "http://localhost/myproject/" (or something like that). I've tried to
> follow the
> instructions in the "faq" file that came with Tomcat and that doesn't work
> (I read somewhere that one of the two ways given in the "faq" file don't
> work so I used the other one... the one that's supposed to work... well..
> actually I used both ways). I have no idea what I'm doing wrong here but
it
> whatever it is it must be something big!
> One thing about that "faq" file. It has a question about exactly what I
> want to do ("Q: What is a web-application? How can I install a new
> web-application?") but it just doesn't seem to work... it seems like
> something more has to be done. So I have a few questions that came into
my
> mind:
>
> 1) It says that I should use a <servlet> element in the web.xml file to
> register a servlet. Can someone tell me how that tag is constructed? I
mean
> what do all the "sub-tags" mean? It also says that I should put the
classes
> in the "classes" folder which is stored in the "WEB-INF" folder. What
about
> packages? Do I need to construct my package structure within the
"classes"
> folder so if I'm
> using "packagename.ClassName" should I make a "packagename" folder inside
> the "classes" folder and then put my "ClassName" class file in there?
>
> 2) What is a WAR file? I'm seeing this thing all over the place and the
> sample thing the "faq" file told me to put in the "server.xml" file (to
make
> my own web-application) looks like this:
> <Context path="/baseball" docBase="baseball"
> defaultSessionTimeOut="30" isWARExpanded="true"
isWARValidated="false"
> isInvokerEnabled="true" isWorkDirPersistent="false"/>
> OK! That's it! "isWARExpanded="true""??? What is that? I'm guessing
> since my context (which I'm again guessing is the same as a web-
application
> in a sense) is WAR expanded then I should probably have a WAR file to go
> with it right? Ok... then tell me how to make that WAR file!
>
> Arrrghhh... only problem with open source is that nobody feels like doing
> the proper documentation for it!
>
> If anyone can help me by pointing out some "real" step-by-step
instructions
> (that actually work) it would be very much appreciated. Or even if someone
> who has had experience with this would be so kind as to let me contact
> him/her with questions about this that would be awsome.
>
> Kind regards from Iceland
> Stefan
>
> UPDATE: I just found some more docs that came with the Tomcat (html
> format). It explains something about what I was asking about (like WAR
> files and such) but nothing that can really be of any use to me. It
doesn't
> say HOW to make the war file, what it actually does and so on.
>
> Any help would be greatly appreciated. Thank you
>
> Stefan
>
>
> --------------------------------------------------------------------------
> To unsubscribe, email: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commmands, email: tomcat-user-help@jakarta.apache.org
>