tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <>
Subject Re: Newbie question
Date Mon, 24 Aug 2009 15:53:28 GMT
Hash: SHA1


On 8/24/2009 10:36 AM, Malladi, Sasikanth wrote:
> I'm using "Core Servlets" by Marty Hall as a guide.

Which edition? It may be out of date.

> I've created a servlet, HelloServlet. Well, it just says "hello".

Can you post the code?

> I've compiled it and put the class file into .../install_dir/webapps/ROOT/WEB-INF/classes/.
> I've enabled the invoker servlet by uncommenting it in .../install_dir/conf/web.xml.

This is fine for testing purposes, but you really should not use the
invoker servlet. Instead, it's easy to enable your servlet in your own
webapp's web.xml:



> I've enabled the servlet reloading in .../install_dir/conf/context.xml.

You should probably not be modifying CATALINA_HOME/conf/context.xml.
Instead, create a file in webapps/ROOT/META-INF/context.xml and put your
configuration there. Remember not to set the "docBase" or "path"
attributes in your <Context> element.

> However, I can't see the servlet in http://myhost:8008/servlet/HelloServlet.
> What am I missing?

I suspect you have a package/class name mismatch with your .class file
and the URL you're using to access the servlet. Disable the invoker
servlet, write a proper web.xml file, and post your code. That will help
a lot.

- -chris
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla -


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message