Darren

Perhaps you have a meta-tag in META-INF suggests re-routing to a different 
class?
I would also make sure you have reloaded your webapp after re-reploying your 
classes

M-
*********************************************************************
This email message and any files transmitted with it contain confidential
information intended only for the person(s) to whom this email message is
addressed.  If you have received this email message in error, please notify
the sender immediately by telephone or email and destroy the original
message without making a copy.  Thank you.



----- Original Message ----- From: "Darren Hall" <[EMAIL PROTECTED]>
To: "'Tomcat Users List'" <users@tomcat.apache.org>
Sent: Monday, July 24, 2006 3:06 PM
Subject: RE: Setting the classpath for my application


I wanted to confirm that jar files in the WEB-INF/lib  directory were
included in the classpath for my application. In reading through the online
documentation for Tomcat I found the following:

"WebappX - A class loader is created for each web application that is
deployed in a single Tomcat 5 instance. All unpacked classes and resources
in the /WEB-INF/classes directory of your web application archive, plus
classes and resources in JAR files under the /WEB-INF/lib directory of your
web application archive, are made visible to the containing web application,
but to no others."

I am doing exactly this. My jar file (foo.jar) is in the
webapps/abc/WEB-INF/lib directory for my 'abc' application. However, in the
Catalina log file, when Tomcat starts, I get a "ClassNotFound -
com.abc.framework.ControlServlet" error. Why can my servlet not be found if
it resides in the jar under the WEB-INF/lib directory???

Any help would be appreciated.

Thanks,

Darren



-----Original Message-----
From: Darren Hall [mailto:[EMAIL PROTECTED] 
Sent: Monday, July 24, 2006 1:59 PM
To: 'Tomcat Users List'
Subject: Setting the classpath for my application

Is the fact that I'm receiving a ClassNotFound error from Tomcat's
ClassLoader for a class that I've created indicative of a bad classpath?
Are jar files stored in WEB-INF/lib automatically included in Tomcat's
classpath for my application?

If so, how do I set the classpath for my application in Tomcat?

Thanks,

Darren

-----Original Message-----
From: Darren Hall [mailto:[EMAIL PROTECTED] 
Sent: Monday, July 24, 2006 11:19 AM
To: 'Tomcat Users List'
Subject: ClassNotFound - Is WEB-INF/lib in my app's classpath?

Ok, I've deployed my application in Tomcat 5.5 on Solaris using the war
deploy feature in the manager.

The application (lets call it 'foo') shows up in the manager as '/foo', so I
know that it deploys. When I look in catalina.log, I see a ClassNotFound
exception, alerting me that the ClassLoader wasn't able to find my
ControllerServlet class. Here is the error from Catalina.log:

2006-07-24 09:38:46,987 DEBUG
org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/foo] -
Sending application start events

2006-07-24 09:38:46,987 DEBUG
org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/foo] -
Starting filters

2006-07-24 09:38:47,002 INFO
org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/foo] -
Marking servlet controller as unavailable

2006-07-24 09:38:47,002 ERROR
org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/foo] - Error
loading WebappClassLoader
  delegate: false
  repositories:
    /WEB-INF/classes/
----------> Parent Classloader:
[EMAIL PROTECTED]
 com.abc.framework.controller.ControlServlet
java.lang.ClassNotFoundException:
com.abc.framework.controller.ControlServlet

My ControlServlet class is located in this jar file
webapps/foo/WEB-INF/lib/abc.jar in the package
com.abc.framework.controller;.

Are the jar files in WEB-INF/lib included in my application's classpath by
default? Do I need to make a classpath change somewhere? Is the fact that
WEB-INF/lib not show up in the repositories listing above meaningful?

Why can't Tomcat's classloader find my ControlServlet class?

Thanks,

Darren


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to