hi, please relate preload to Init in the below lines I think that the Init Servlet should be in the web-inf\classes directory even I have had similar problems... if I have a jar file in my application\web-inf\lib dir then I can only access these files outside the Init servlet.If I have to access these classes in the Init servlet then I'd have to hard code the classpath like "C:\.....application\web-inf\lib\my-pkg.jar" but the same doesn't need to be done when I place the jar file in the \servers\default\lib... basically I think at start up the web-inf\lib is not in the classpath in my JRUN setup. If anyone has experiences do help rgds Sashi -----Original Message----- From: Tom Duffy [mailto:[EMAIL PROTECTED]] Sent: Friday, May 11, 2001 6:30 AM To: JRun-Talk Subject: RE: preload servlet error Thanks for the reply. I've tried that, and I've also tried loading them as 'loose' classes (taken them out of the package and put them in the testServlet.class file in the /classes directory). no luck. At 03:03 PM 05/10/2001 -0600, you wrote: >Isn't the servlet class file supposed to go in the web-inf\classes directory >instead of web-inf\lib? Your full path would be >c:\progra~1\allaire\jrun\servers\default\appname-app\web-inf\classes\testPa c >kage\testServlet.class. > >I'm not sure but I would try that. > >-----Original Message----- >From: Tom Duffy [mailto:[EMAIL PROTECTED]] >Sent: Thursday, May 10, 2001 9:54 AM >To: JRun-Talk >Subject: preload servlet error > > >Hello, > I'm trying to preload a servlet and continue to get the following error >message in the event log for the server: > >05/10 11:44:16 error (JRun) Could not pre-load servlet: testServlet >[javax.servlet.ServletException: Could not instantiate >testPackage.testServlet] >[1]java.lang.ClassCastException: testPackage.testServlet > >The servlet I'm trying to preload is >appname-app/WEB-INF/lib/testPackage/testServlet.class > >I've defined this servlet and set it to preload by using the Serlet >Definitions and Set preLoad Order in the JMC and it appears to make the >correct changes to the web.xml. > >I don't get this error if when I do not preload the server. > >Any advice? > >Tom D. > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.cfm Archives: http://www.mail-archive.com/[email protected]/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists
