From: Mike S. <msc...@ao...> - 2003-01-14 21:28:22
|
jc...@di... wrote: > > FWIW - my auto-dump only kicks in at the end of the arg-list ( or > should ). > As I scan @_, I just print non-refs, thus avoiding the needless > encapsulation > of string-args into output like; Problem is that some appenders require a certain number of arguments to be passed without any interpretation (please see the thread on "Patch for suggested new behaviour" on this list) -- we need to find a solution which serves both purposes, special appenders and special parameter treatment. > > autocat constructs the category from info available from caller(), the > 1st 4 are most useful. > > ($package, $filename, $line, $subroutine, $hasargs, > $wantarray, $evaltext, $is_require, $hints, $bitmask) = > caller($i); > > If theyre put in the right order, (typically scoped - like code): > > "$filename.$package.$subroutine.$line", > > then the log-config file can control which messages are logged, in a > fashion consistent with the scoping. Ah, now I understand. I like the idea of being able to manipulate logging behaviour at this very granular level. However, the performance impact is overwhelming: Every log statement, no matter if it's actually active or not, will cause a call to caller() and get_logger(). This way, it doesn't really matter if you enable or disable logging, the load on the system will always like if you enabled DEBUG logging all over the place. That's something log4j has been designed to avoid. Is there a way of getting around this? -- -- Mike Mike Schilli log...@pe... |