[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[cgiapp] CAP::LogDispatch


Hello,

I have a circumstance in CAP::LogDispatch where it would be really handy to extract one of the output modules that Log::Dispatch is using so that I might call methods on it.

To illustrate:

$self->log_config(
    LOG_DISPATCH_MODULES => [
    {
        module    => 'Log::Dispatch::DBI',
        name      => 'dbi',
        dbh       => $self->param("dbh"),
        table     => "www_message_log",
        min_level => $config{DEBUG_LEVEL},
    },
    {
        module    => 'Log::Dispatch::Buffer',
        name      => 'debug',
        min_level => $config{DEBUG_LEVEL},
    },
]);

I'm using Log::Dispatch::Buffer to catch everything that happens over the course of one request for the app. At the end, I'd love to dump the contents of that to a popup, but I can't seem to extract that object and call the proper method. Something like:

my $output = $self->log("debug")->fetch;

would be exceptionally handy.

Does it already do this and I missed something in the POD about it?

Thanks in advance!
Jason

---------------------------------------------------------------------
Web Archive:  http://www.mail-archive.com/suppressed/
             http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: suppressed
For additional commands, e-mail: suppressed


Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.