in reply to Log4perl script logs OK only initially
Your log method expects three arguments, but you are passing it as a log argument to Schedule::Cron, which is only going to call it with two arguments, and the first one will be either 0, 1, or 2 depending on the level of the message, so when you call Log directly in your TestSub, it works as expected, but when Schedule::Cron calls it, you are only logging the first argument, which is 0, and ignoring the second one (which you assigned to $subject, but then didn't do anything with). The Schedule::Cron documentation includes an example of how to use Log::Log4perl as a logger.
We're not surrounded, we're in a target-rich environment! |
---|
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Log4perl script logs OK only initially
by bowei_99 (Friar) on Dec 30, 2007 at 05:54 UTC | |
by bowei_99 (Friar) on Jan 02, 2008 at 18:10 UTC |