[Catalyst] Selective debug output

Karim Nassar karim.nassar at acm.org
Wed Nov 7 23:24:24 GMT 2007

Thanks for the links! Looks like Log4Perl does what I need. Wish I knew that
6 months ago... :-/

Karim Nassar

On 11/7/07, Jonathan Rockway <jon at jrock.us> wrote:
> Karim Nassar wrote:
> > At my former employer, we had a logging infrastructure, but it had to
> > work with more than just catalyst, so it was not optimal.
> I see what you're saying, but Catalyst can easily support custom
> logging.  You can make $c->log return whatever you want (see
> Catalyst::Log::Log4perl for an example).  From there, you can call any
> methods that you want on the object, so you can log whatever you want.
> CPAN components assume that $c->log->can(all(info debug warn error)) is
> true... but you probably don't care about internal debugging information
> for CPAN modules in production, so you can just turn their logging off
> and only worry about messages generated by your application.
> >
> > I feel what is needed is the ability to log in any module such that I
> > can debug/log at will, and not have to worry about removing debug
> > statements:
> Roll your own.
> > In a production environment, it'd be nice to be able to send certain
> > log levels through other channels as well i.e.: alternate log files or
> > some monitoring program's mechanism, but having the rest in place
> > first is extremely nice during development, and makes site monitoring
> > easier.
> log4perl does this.
> Hope this points you in the right direction.  Let me know if I'm
> completely off-base here :)
> Regards,
> Jonathan Rockway
> _______________________________________________
> List: Catalyst at lists.scsys.co.uk
> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
> Searchable archive:
> http://www.mail-archive.com/catalyst@lists.rawmode.org/
> Dev site: http://dev.catalyst.perl.org/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.scsys.co.uk/pipermail/catalyst/attachments/20071107/ea799=

More information about the Catalyst mailing list