Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

DBIx::Log4perl -- how to log my own errors

by tune (Curate)
on Jan 04, 2011 at 17:09 UTC ( #880419=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
     my $logfile = "/tmp/sybase_wrapper_xlog_$callerfile";
     Log::Log4perl::init(\ qq{
    ...
            log4perl.appender.A1.layout   = Log::Log4perl::Layout::Pattern
    +Layout
            log4perl.appender.A1.layout.ConversionPattern=%d [%r] %P %C %p
    +> %H:%F{1}:%L %M - %m%n
     });
    
  2. or download this
         my $log = Log::Log4perl->get_logger();  
    
         $log->debug("Debug message");
         $log->info("Info message");
         $log->error("1234 Error message");
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://880419]
Approved by Corion
Front-paged by toolic
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (3)
As of 2020-11-28 01:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?