Trying my first "Hello World" app with Tomcat which is much like the beer app in HFSJ. I'm using Tomcat 5.5 on XP. I've read the javaranch FAQ on Tomcat and I understand that Tomcat is not finding my target file, form.html.
Modeling after the examples on HFJS p72-77, I have my form.html at ...
Again, I'm following closely the deployment example on p73. I corrected a typo in my web.xml but I suspect that's an unrelated issue. Everything under WEB-INF is deployed as described in the HFSJ example.
- Interestingly, if I try http://localhost:8080/tomcat-docs (which is there thanks to the Tomcat install) I get that index.html just fine. It's strange. [ September 04, 2008: Message edited by: Bear Bibeault ]
Joined: Feb 25, 2007
The directory hierarchy diagram didn't come through with the leading spaces, but yes, WEB-INF is under HelloWorldOne.
At the risk of sounding like a total moron, I don't know what that phrase "context shows in the manager app" means. What is the manager app? I see Tomcat running in a DOS shell and I can invoke it using a browser, and my app is HelloWorldOne. But what is the manager app?
The manager app shows you the contexts that are running in Tomcat and allows you to stop and start them individually. If the context is listed, the manager app will let you know if it's running or not. If it's not listed, the context isn't even being recognized.
I wrote an article on setting up Tomcat and the manager app for my jQuery in Action book. Visit the book's web site and download the example code. A PDF named tomcat.pdf will be found in the chapter8 folder. It will walk you through setting up a context and the manager application. [ September 04, 2008: Message edited by: Bear Bibeault ]
William and Bear, thanks for both of your replies.
Bear, your pdf was very eye-opening. I can run the Application Manager now and my /HelloWorldOne app appears on Applications, Running=false and Sessions=0. Is "Sessions" what you mean by "context" as in Session Context, or is there something else I'm missing? Sessions remains 0 when I try to invoke my HelloWorldOne app in another browser window, and of course I still get the 404 error.