On Thu, May 15, 2008 at 11:01:35PM -0700, Mike Schilli wrote: > > You need to call the appender's layout() method to set the layout, other > than that, the code above looks ok to me at first glance. It's fairly > unusual to use Perl code to init Log4perl, most of the time people > either use easy_init() or init($conf_file).
The log4perl config is not that complex, but we do have a few appenders. The problem is the log4perl.conf file is part of the application (it's in subversion with the rest of the code). But, the application has to run in different environments (development, testing, staging, production) so we need slightly different configurations under each environment. So, I was looking at having a single log4perl config and then using environment-specific config files to alter the behavior. The log message pattern might be the same under each mode, but the destination file might be different or the "owner" of the file might be different, for example. I have a way to handle this right now, but it just means I need separate log4perl config files for each operating environment. So, I end up duplicating the config for the majority of the log4perl config. I can see it would be handy to have a base config file and then be able to "override" just parts of the config that are different. -- Bill Moseley [EMAIL PROTECTED] ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ log4perl-devel mailing list log4perl-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/log4perl-devel