[log4perl-devel] log4perl appenders with warp_message=0 (fwd)

2008-05-13 Thread Mike Schilli
(forwarded with permission) Hi Mike. I've been enjoying Log::Log4perl (using 1.13). Thank-you. Until I decided to write a pair of appenders. One of them is a fancy file appender and it works nicely. The other logs an event to Netcool (specifying warp_message=0) and it works fine. It allows y

Re: [log4perl-devel] log4perl appenders with warp_message=0 (fwd)

2008-05-13 Thread Mike Schilli
On Fri, 9 May 2008, Erskine, Thomas (IT) wrote: > The other logs an event to Netcool (specifying warp_message=0) and it > works fine. It allows you to call log like: > > $logger->log($level, $msg, $key) > > so that you can specify a Netcool alert key. > > Then comes the problem: I made a conf

Re: [log4perl-devel] log4perl appenders with warp_message=0

2008-05-13 Thread Mike Schilli
On Tue, 13 May 2008, Erskine, Thomas (IT) wrote: > I do indeed want > > $logger->log($level, $msg, $key) > > to be dealt with differently depending on the appender it ends up on. > That's part of the point of having different appenders; they ought to be > independant. The problem is that it

Re: [log4perl-devel] setting defaults for appenders

2008-05-13 Thread Bill Moseley
On Mon, May 12, 2008 at 02:21:23PM -0700, Jonathan Swartz wrote: > I've got a growing number of log files for different categories that I > would like to all have the same layout and pattern, e.g. You can use "Variable Substitution" as described in the man page, but that still seems awkward. -

Re: [log4perl-devel] log4perl appenders with warp_message=0

2008-05-13 Thread Erskine, Thomas (IT)
Hi Mike. While warp_message is indeed an appender setting, if you have two appenders, one with warp_message=0 and one without, then you'll get the mess I got: the one with will work fine and will have access to extra args separately, but the one without will mash the args into a single message.

[log4perl-devel] Understanding the config

2008-05-13 Thread Bill Moseley
I inherited an existing Log4perl configuration, and I think I'm missing some key point. The config file starts out: log4perl.rootLogger = INFO, syslogAppender, screenAppender >From the examples I've seen and the ::Config docs I thought it should be "log4perl.logger" not "log4perl.rootLogger". Y

Re: [log4perl-devel] setting defaults for appenders

2008-05-13 Thread Bill Moseley
On Mon, May 12, 2008 at 02:21:23PM -0700, Jonathan Swartz wrote: > I've got a growing number of log files for different categories that I > would like to all have the same layout and pattern, e.g. You can use "Variable Substitution" as described in the man page, but that still seems awkward. -

Re: [log4perl-devel] setting defaults for appenders

2008-05-13 Thread Jonathan Swartz
> On Fri, 9 May 2008, Jonathan Swartz wrote: > >> I've got a growing number of log files for different categories >> that I >> would like to all have the same layout and pattern, e.g. > > Hi Jonathan, > > this is one of the items on my todo-list: To have an inheritance > mechanism that lets you s