Catalyst::Log::Log4perl

Log::Log4perl logging for Catalyst
Download

Catalyst::Log::Log4perl Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • Tomas Doran
  • Publisher web site:
  • http://search.cpan.org/~bobtfish/

Catalyst::Log::Log4perl Tags


Catalyst::Log::Log4perl Description

Log::Log4perl logging for Catalyst Catalyst::Log::Log4perl is a Perl module that provides a Catalyst::Log implementation that uses Log::Log4perl as the underlying log mechanism. It provides all the methods listed in Catalyst::Log, with the exception of: levels enable disableThese methods simply return 0 and do nothing, as similar functionality is already provided by Log::Log4perl.These methods will all instantiate a logger with the component set to the package who called it. For example, if you were in the MyApp::C::Main package, the following: package MyApp::C::Main; sub default : Private { my ( $self, $c ) = @_; my $logger = $c->log; $logger->debug("Woot!"); }Would send a message to the Myapp.C.Main Log::Log4perl component.SYNOPSISIn MyApp.pm: use Catalyst::Log::Log4perl; # then we create a custom logger object for catalyst to use. # If we dont supply any arguments to new, it will work almost # like the default catalyst-logger. __PACKAGE__->log(Catalyst::Log::Log4perl->new()); # But the real power of Log4perl lies in the configuration, so # lets try that. example.conf is included in the distribution, # alongside the README and Changes. __PACKAGE__->log(Catalyst::Log::Log4perl->new('example.conf'));And later... $c->log->debug("This is using log4perl!"); Requirements: · Perl


Catalyst::Log::Log4perl Related Software