The moose likes Tomcat and the fly likes WebApps not isolated in Tomcat? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Bookmark "WebApps not isolated in Tomcat?" Watch "WebApps not isolated in Tomcat?" New topic

WebApps not isolated in Tomcat?

Robert Gorn

Joined: Jan 10, 2007
Posts: 15
Hi, there is a Tomcat 5.5 instance, and I've deployed two webapps by dropping the WAR files into the webapps folder.
The database connection string, respectively, is read from a properties file, which resides in WEB-INF/classes.
The code to read a property is simply,

Now, the problem is, both webapps are using the same properties file, the one of webapp1.

I made sure that's a fact, and also made sure there are no offending JARs in $CLASSPATH, $TOMCAT_HOME/webappX/WEB-INF/lib or $TOMCAT_HOME/common.

Any ideas???


Edit: BTW, the method that retrieves the values from the properties file is static.
Edit: Strange enough, some legacy webapps within the same Tomcat instance are throwing errors now, because Java method signatures have changed.
Thus, actually a set of WEB-INF/classes gets loaded from other webapps(!).

[ May 23, 2007: Message edited by: Robert Gorn ]
[ May 23, 2007: Message edited by: Robert Gorn ]
I agree. Here's the link:
subject: WebApps not isolated in Tomcat?
It's not a secret anymore!