logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Stauffer" <stauffer.ja...@gmail.com>
Subject Re: Was ThreadFileAppender ever added to the distribution?
Date Thu, 03 Aug 2006 14:24:53 GMT
If you create the logger in each method like the following then it
should work fine:
Logger logger = Logger.getLogger(Thread.currentThread().getName() +
"." + getClass().getName());

On 8/3/06, Mills Maurice-EMM006C <EMM006C@motorola.com> wrote:
> After some very extensive searching, I found a ThreadFileAppender that
> was written by Jim Moore (see
> http://mail-archives.apache.org/mod_mbox/logging-log4j-user/200106.mbox/
> %3CE70AFA7E9123D51199AE0008C78699FD092218@LMOXCH05%3E) back in June
> 2001.  I think this is very close to something I need to use but don't
> see that it was ever added to the Log4J distributions.
> Basically I am writing a multi threaded process that needs to maintain
> (and eventually email) the log output for each individual thread
> separately.  I can create a new Logger when each thread is instantiated,
> however the actual output is generated by additional classes that are
> used by every thread, so I believe I would still have the same problem.
> Is there a better way to handle this?
> We are using log4j-1.2.9 and J2SE 1.4.2
> Thanks,
> Maury

James Stauffer
Are you good? Take the test at http://www.livingwaters.com/good/

To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org

View raw message