RE: Tomcat 6.0 loading servlet twice
> From: Ani [mailto:jadhao.anirud...@gmail.com] > Subject: Re: Tomcat 6.0 loading servlet twice > > I have entry in context tag of server.xml Don't put elements in server.xml. For webapps placed in the appBase directory, the element belongs in the webapp's META-INF/context.xml file. For webapps placed outside of the appBase directory, the element must go into conf/Catalina/[host]/[appName].xml. You must not use the path attribute, and only use the docBase attribute for the second case. > These two web app's WEB-INF folder contains servlet-api.jar Never, never put servlet-api.jar inside a webapp. Don't put any other jars in your webapp that the container provides. Clean up your mess, try it again, and let us know what the result is. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 6.0 loading servlet twice
What m I thinking was , I have entry in context tag of server.xml as where as I have two web applicatio folders named website and website_old in side C:\Program Files\Avaya/comp. These two web app's WEB-INF folder contains servlet-api.jar I did some rnd by changing the same of website_old to old_website , that time tomcat went well. It didnt reloaded the serlvet again. So I am thinking tht the docBase might search for applications starting with names from website (in this case). Whats your thot? --Ani On Thu, Jan 29, 2009 at 20:08, Stephen Souness wrote: > Hi, > > If you go in via Tomcat's Manager app, do you see more webapps than you > expect? > > A long time ago I made the mistake of deploying apps under the webapps > directory as well as configuring them with their own context - this resulted > in those particular applications being loaded twice. > > Also, make sure you clean out Tomcat's work directory - just to be sure > that your config changes are taking effect. > > -- > Stephen Souness > > > > Ani wrote: > >> >>> >>> On Thu, Jan 29, 2009 at 11:40, Ani wrote: >>> >>> Hello, I have a web application in which I am facing one wiered pbm. I see tomcat loading servlet twice , on which my application logic is failing and quits. Getting below error in log file. My findings : One thing I did was , inside comp folder I made a copy of website folder and renamed it to website_old. Now both folders contains servlet.jar. Will it be causing a pbm??? == Jan 29, 2009 10:48:34 AM org.apache.catalina.loader.WebappClassLoader validateJarFile INFO: validateJarFile(.\comp\website_old\WEB-INF\lib\servlet.jar) - jar no t loaded. See Servlet Spec 2.3, section 9.7.2. Offending class: javax/servlet/Servlet.class == I have Server.xml has an entry of below >>> reloadable="false" crossContext="true" /> So tomcat should look for website folder in the specified directory, but in the C:\Program Files\Avaya/comp directory, there are two directories , website and website_old. Why tomcat is searching for C:\Program Files\Avaya/comp/website_old application if it gets the C:\Program Files\Avaya/comp/website . ?? I have tomcat6. Any reason?? --Ani >>> >> > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > >
Re: Tomcat 6.0 loading servlet twice
Hi, If you go in via Tomcat's Manager app, do you see more webapps than you expect? A long time ago I made the mistake of deploying apps under the webapps directory as well as configuring them with their own context - this resulted in those particular applications being loaded twice. Also, make sure you clean out Tomcat's work directory - just to be sure that your config changes are taking effect. -- Stephen Souness Ani wrote: On Thu, Jan 29, 2009 at 11:40, Ani wrote: Hello, I have a web application in which I am facing one wiered pbm. I see tomcat loading servlet twice , on which my application logic is failing and quits. Getting below error in log file. My findings : One thing I did was , inside comp folder I made a copy of website folder and renamed it to website_old. Now both folders contains servlet.jar. Will it be causing a pbm??? == Jan 29, 2009 10:48:34 AM org.apache.catalina.loader.WebappClassLoader validateJarFile INFO: validateJarFile(.\comp\website_old\WEB-INF\lib\servlet.jar) - jar no t loaded. See Servlet Spec 2.3, section 9.7.2. Offending class: javax/servlet/Servlet.class == I have Server.xml has an entry of below So tomcat should look for website folder in the specified directory, but in the C:\Program Files\Avaya/comp directory, there are two directories , website and website_old. Why tomcat is searching for C:\Program Files\Avaya/comp/website_old application if it gets the C:\Program Files\Avaya/comp/website . ?? I have tomcat6. Any reason?? --Ani - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 6.0 loading servlet twice
> > > > On Thu, Jan 29, 2009 at 11:40, Ani wrote: > >> Hello, >> I have a web application in which I am facing one wiered pbm. I see tomcat >> loading servlet twice , on which my application logic is failing and quits. >> Getting below error in log file. >> My findings : One thing I did was , inside comp folder I made a copy of >> website folder and renamed it to website_old. Now both folders contains >> servlet.jar. Will it be causing a pbm??? >> == >> Jan 29, 2009 10:48:34 AM org.apache.catalina.loader.WebappClassLoader >> validateJarFile >> INFO: validateJarFile(.\comp\website_old\WEB-INF\lib\servlet.jar) - jar no >> >> t loaded. See Servlet Spec 2.3, section 9.7.2. Offending class: >> javax/servlet/Servlet.class >> == >> >> >> I have >> Server.xml has an entry of below >> >> > reloadable="false" crossContext="true" /> >> >> So tomcat should look for website folder in the specified directory, but >> in the C:\Program Files\Avaya/comp directory, there are two directories , >> website and website_old. >> Why tomcat is searching for C:\Program Files\Avaya/comp/website_old >> application if it gets the C:\Program Files\Avaya/comp/website . ?? >> I have tomcat6. >> >> Any reason?? >> --Ani >> > >