This is a little off topic, but I tried your suggestions. However there doesn't seem to be an option to set the root application without renaming the WAR to ROOT.war, or is there.
I tried your suggestions as well as the suggestions from here: http://mail-archives.apache.org/mod_mbox//tomcat-users/200902.mbox/%3c499fe497.2000...@ice-sa.com%3e Besides the connection problems my configuration worked really well and allowed me to configure all I needed in one file outside the WAR, as well as set the application accessible on the root (/) path. I see that using a separate file has it's merits in some cases, however right now I can't get the application running on the / path without renaming it. Don't really want to rename it as this only seems to work on Tomcat. Ideally I would like to set the deployment path to / in META-INF/context.xml but configure the database connection outside the WAR to allow me to change between different database. Any other suggestion on my Connection issue. I set the maxActive to 200 and after a day ended up with 21 in numActive state. So by increasing my upper limit I can increase the time between restarts. However this is really just a hack until I figure this out. Thanks for all your suggestions. Regards Alex On 3 Feb 2010, at 00:15, Caldarale, Charles R wrote: >> From: Alexander Hartner [mailto:a...@j2anywhere.com] >> Subject: Re: Active DataSource Connection count never decreasing with >> PostgreSQL >> >>> Put this into either META-INF/context.xml within your WAR/webapp >>> directory, or into CATALINA_BASE/Catalina/[hostname]/ROOT.xml >>> >>> Remove the "path" and "docBase" attributes when you move the >>> <Context> element. >> >> I really like it that way as it allows me to configure what I need to >> in one central place without having to touch or expand the WAR file. > > And it breaks things. You are now getting double deployment, once under the > name AddressBookServer and once again as ROOT. Do it the right way, by > renaming your .war file to ROOT.war, and placing the <Context> element in > conf/Catalina/[host]/ROOT.xml - that also avoids having to change the > contents of the .war file. (Note that Chris' suggesting was missing part of > the path.) As Chris said, when you do that, remove the path and docBase > attributes. > >> This also works great for me. My database folder is relative the the >> startup script. > > That's really asking for trouble. A parser has complete freedom to ignore > any .. entry in a URL, so if it happens to be working now, you're extremely > lucky, and there's no guarantee it will work tomorrow. The URL is *not* > relative to any current directory, since it doesn't target the file system > per se. > > - 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 > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org