Thanks, very interesting. Does this mean that I will have similar issues with my PoolManager or does it not use a static class reference(like Singleton)?
Will all my Singleton's be shared between webapps? Thanks for your time, Greg -----Original Message----- From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]] Sent: Wednesday, August 14, 2002 3:06 PM To: Struts Users Mailing List Subject: Re: Cannot specify multiple log files with CommonsLogging/Log4j On Wed, 14 Aug 2002, Greg Hess wrote: > Date: Wed, 14 Aug 2002 14:36:47 -0400 > From: Greg Hess <[EMAIL PROTECTED]> > Reply-To: Struts Users Mailing List <[EMAIL PROTECTED]> > To: Struts Mail List <[EMAIL PROTECTED]> > Subject: Cannot specify multiple log files with CommonsLogging/Log4j > > Hi All, > > I am deploying multiple instances of the same web app in the same web > container Resin2.1.2. I would like to have each web application use a unique > log file to simplify bug tracking. I am specifying the > log4j.appender.rolling.File=logs/appinstance1701794474_65.log with a new log > file for each deployed app. > > I had expected when each new app is initialized it would initialize its > logging implementation through Commons.logging and > > private static final Log m_log = LogFactory.getLog(SQLManager.class); > > Would return the logging implementation for this web app. What happens is > that I receive a org.apache.commons.logging.Log but it uses the log file of > the first initialized web app. > > I didn't think this was possible as each web app runs in its own VM and > LogFactory.getLog(SQLManager.class) could only return instantiated Log > implementation for the given web app. > Does Resin really do that (VM per webapp)? That would be pretty surprising. On Tomcat, or other containers that use a single VM for all webapps, you can accomplish what you are after by putting commons-logging.jar, Log4J, and all of your classes inside the webapp, instead of in a shared directory. Then, "static" variables are per-webpp instead of global. > Does anyone know why this is happening? > > Thanks for your time, > > Greg > Craig -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

