RE: Deploying a simple servlet
That was the last problem. What I did was to remove the package statement from my java code and the servlet ran with out a problem. Thank you all for your assistance! -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 02, 2004 1:01 PM To: Tomcat Users List Subject: RE: Deploying a simple servlet Hi, > TestingServlet The servlet-class needs to match the fully-qualified class name of your servlet. So if TestingServlet.java has "package myApp;" at the top, servlet-class is myApp.TestingServlet. Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Deploying a simple servlet
Leon, I've set up a directory structure for this app exactly like the servlet examples structure and after making changes to web.xml I'm recieving the following root cause error: java.lang.NoClassDefFoundError: TestingServlet (wrong name: myApp/TestingServlet) Is your TestingServlet class in a package? If so, you need to give the fully-qualified class name in your web.xml file. If it's not in a package, I've heard many reports that it simply won't work :( Try putting your servlet class into a package, updating your web.xml file and trying again. -chris signature.asc Description: OpenPGP digital signature
RE: Deploying a simple servlet
Hi, > TestingServlet The servlet-class needs to match the fully-qualified class name of your servlet. So if TestingServlet.java has "package myApp;" at the top, servlet-class is myApp.TestingServlet. Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Deploying a simple servlet
I've edited the web.xml file to contain the following: http://java.sun.com/dtd/web-app_2_3.dtd";> Testing TestingServlet Testing /Testing I've set up a directory structure for this app exactly like the servlet examples structure and after making changes to web.xml I'm recieving the following root cause error: java.lang.NoClassDefFoundError: TestingServlet (wrong name: myApp/TestingServlet) -Original Message- From: Christopher Schultz [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 02, 2004 11:57 AM To: Tomcat Users List Subject: Re: Deploying a simple servlet Leon, > I'm new to tomcat and am trying to run a very simple hello world type of > servlet. I've configured the web.xml to mimic a similar servlet in tomcat > examples. Still while all the example servlets from tomcat work mine fails > to run. > > I receive the following message: > > HTTP Status 404 - /MyApp/servlet/Testing > > I would greatly appreciate any advice. In the newer versions of Tomcat, the 'invoker' servlet is disabled by default. The best way to get your servlet running it to create a element in your web.xml and then use your mapped URL to access the servlet (instead of using a URL like /context/servlet/ClassName). -chris - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Deploying a simple servlet
The name of the servlet class is TestingServlet.class Here are the contants of my web.xml file for this servlet. http://java.sun.com/dtd/web-app_2_3.dtd";> Testing TestingServlet -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 02, 2004 11:48 AM To: Tomcat Users List Subject: RE: Deploying a simple servlet Hi, If your servlet class name is com.yourcompany.YourServlet, add the following to your web.xml: YourServlet com.yourcompany.YourServlet YourServlet /servlet/Testing Make sure the compiled servlet class is under the appropriate directory of your app's WEB-INF/classes directory or packaged in a jar in WEB-INF/lib. Restart tomcat. If your app is named MyApp, you will be able to access your servlet at http://yourhost:yourport/MyApp/servlet/Testing Yoav Shapira Millennium ChemInformatics >-Original Message- >From: Leydhershnayder, Leon A. [mailto:[EMAIL PROTECTED] >Sent: Tuesday, March 02, 2004 11:45 AM >To: [EMAIL PROTECTED] >Subject: Deploying a simple servlet > >I'm new to tomcat and am trying to run a very simple hello world type of >servlet. I've configured the web.xml to mimic a similar servlet in tomcat >examples. Still while all the example servlets from tomcat work mine fails >to run. > >I receive the following message: > >HTTP Status 404 - /MyApp/servlet/Testing > >I would greatly appreciate any advice. > > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Deploying a simple servlet
Leon, I'm new to tomcat and am trying to run a very simple hello world type of servlet. I've configured the web.xml to mimic a similar servlet in tomcat examples. Still while all the example servlets from tomcat work mine fails to run. I receive the following message: HTTP Status 404 - /MyApp/servlet/Testing I would greatly appreciate any advice. In the newer versions of Tomcat, the 'invoker' servlet is disabled by default. The best way to get your servlet running it to create a element in your web.xml and then use your mapped URL to access the servlet (instead of using a URL like /context/servlet/ClassName). -chris signature.asc Description: OpenPGP digital signature
Re: Deploying a simple servlet
Usually the problem is on your deployment descriptor. Double-check it or post it for help. Thanks. - Original Message - From: "Leydhershnayder, Leon A." <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, March 02, 2004 10:44 AM Subject: Deploying a simple servlet > I'm new to tomcat and am trying to run a very simple hello world type of > servlet. I've configured the web.xml to mimic a similar servlet in tomcat > examples. Still while all the example servlets from tomcat work mine fails > to run. > > I receive the following message: > > HTTP Status 404 - /MyApp/servlet/Testing > > I would greatly appreciate any advice. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Deploying a simple servlet
Hi, If your servlet class name is com.yourcompany.YourServlet, add the following to your web.xml: YourServlet com.yourcompany.YourServlet YourServlet /servlet/Testing Make sure the compiled servlet class is under the appropriate directory of your app's WEB-INF/classes directory or packaged in a jar in WEB-INF/lib. Restart tomcat. If your app is named MyApp, you will be able to access your servlet at http://yourhost:yourport/MyApp/servlet/Testing Yoav Shapira Millennium ChemInformatics >-Original Message- >From: Leydhershnayder, Leon A. [mailto:[EMAIL PROTECTED] >Sent: Tuesday, March 02, 2004 11:45 AM >To: [EMAIL PROTECTED] >Subject: Deploying a simple servlet > >I'm new to tomcat and am trying to run a very simple hello world type of >servlet. I've configured the web.xml to mimic a similar servlet in tomcat >examples. Still while all the example servlets from tomcat work mine fails >to run. > >I receive the following message: > >HTTP Status 404 - /MyApp/servlet/Testing > >I would greatly appreciate any advice. > > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Deploying a simple servlet
I'm new to tomcat and am trying to run a very simple hello world type of servlet. I've configured the web.xml to mimic a similar servlet in tomcat examples. Still while all the example servlets from tomcat work mine fails to run. I receive the following message: HTTP Status 404 - /MyApp/servlet/Testing I would greatly appreciate any advice. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Deploying a simple servlet
I have Apache and Tomcat running on NT. I am trying to deploy a simple servlet which was developed in JBuilder4. The servlet runs fine using JBuilder's built in Tomcat. The shtml file which I am using, displays the source in the browser rather than the intended web page. I am not sure if this is the only problem. I have downloaded the latest JRE from Sun and also tried converting the html file using Sun's html converter. This did not help. Thank you, Mike M 757-686-2440