dcsimg
Tomcat is not loading classes properly
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Tugba_Saw
Posted On:   Friday, June 21, 2002 01:17 PM

If I place the servlet class as /WEB-INF/classes/MyServlet.class, Tomcat finds it fine. If I place the servlet class as /WEB-INF/classes/com/mycompany/servlet/MyServlet.class directory, I get 404 error. So I can't use package names right now. I am guessing that my classpath is not interepreted properly. I don't have anything set in the web.xml file. When I start Tomcat, I see /path/to/my/WEB-INF/classes (not including ../com/mycompany/.. part) in the CLASSPATH. What else do I need to look at? I appreciate any help. Tugba Saw    More>>

If I place the servlet class as /WEB-INF/classes/MyServlet.class, Tomcat finds it fine.


If I place the servlet class as /WEB-INF/classes/com/mycompany/servlet/MyServlet.class directory, I get 404 error.


So I can't use package names right now. I am guessing that my classpath is not interepreted properly.


I don't have anything set in the web.xml file.

When I start Tomcat, I see /path/to/my/WEB-INF/classes (not including ../com/mycompany/.. part) in the CLASSPATH. What else do I need to look at?



I appreciate any help.


Tugba Saw

   <<Less

Re: Tomcat is not loading classes properly

Posted By:   AlessandroA_Garbagnati  
Posted On:   Saturday, June 22, 2002 03:06 AM

Hi,

The classpath is perfect.

How are you calling your servlet when you put the class file in the packaged directory? (/WEB-INF/classes/com/mycompany/servlet/MyServlet.class)
About | Sitemap | Contact