You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Bill Halpin <bi...@schwoo.com> on 2001/12/04 17:20:36 UTC

Newbie - class loading issue

Hello Folks! I was recently assigned a POC project that includes some web
development which I am using Tomcat 4.0.1 to do.  I've only been using
Tomcat for about 1.5 weeks so I'm extremely wet behind the ears.

I've consulted the documentation and searched the list archives looking for
an answer to my problem but cant seem to find one.  Right now, I am simply
trying to use a bean to gather data from a form and return the data to the
screen.  When I run the jsp to do this, I get one of two different "class
not found" errors.  I am not deploying the app using a WAR file, right now I
just have the jsp file in the root directory and the class files in
WEB-INF/classes.  The bean class is in the package login.  So the full path
for the class is WEB-INF/classes/login/UserBean.class.

I've also tried the following:

1.  Recompiled the class without the package and placed the class in
WEB-INF/classes.

2.  Created jar file with package.  Placed the jar file in WEB-INF/lib.
This also did not work, so I tried /lib and /common/lib which also didnt
work.  I tried all of these locations with and without the package
designation.

3.  I've added the individual class and the jar file to the classpath.

I am sure I am making a simple mistake but cant seem to figure out what that
mistake is.  According to (my understanding of) the documentation, placing
the class files in WEB-INF/classes should be all I need to make them
accessible to the jsp, am I mistaken? The text from the errors was rather
lengthy, so I have not included it, if necessary I would gladly forward it
on.

If anyone has a possible solution, or perhaps advice on other sources to
peruse to solve the problem, I would greatly appreciate it.

Thanks

-b

Bill Halpin
Schwoo, Inc
412-481-3301
bill@schwoo.com