Catalyst::Controller::LeakTracker - Inspect leaks found by Catalyst::Plugin::Leaktracker
package MyApp; use Catalyst qw/ LeakTracker /; #### package MyApp::Controller::Leaks; use base qw/Catalyst::Controller::LeakTracker/; sub default : Private { my ( $self, $c ) = @_; $c->forward("list_request"); # if you are so inclined } 1;
This controller uses Catalyst::Controller::LeakTracker to display leak info on a per request basis.
List the leaking requests this process has handled so far.
If the all parameter is set to a true value, then all requests (even non leaking ones) are listed.
all
Detail the leaks for a given request, and also dump the event log for that request.
Detail the object created in $event_id.
Displays a stack dump, a Devel::Cycle report, and a Data::Dumper output.
If the maxdepth param is set, $Data::Dumper::Maxdepth is set to that value.
maxdepth
$Data::Dumper::Maxdepth
Artificially leak some objects, to make sure everythign is working properly
This is yucky example code. But it's useful. Patches welcome.
Instead of yucky HTML strings
I can't do that well, I didn't bother trying
<pre> ... </pre>
Only goes so far...
The event log is in most dire need for this.
Of objects, requests, etc. Javascript or serverside, it doesn't matter.
Maybe it's useful for someone.
Devel::Events, Catalyst::Plugin::Leaktracker, http://blog.jrock.us/articles/Plugging%20a%20leaky%20whale.pod, Devel::Size, Devel::Cycle
This module is maintained using Darcs. You can get the latest version from http://nothingmuch.woobling.org/Catalyst-Controller-LeakTracker/, and use darcs send to commit changes.
darcs send
See http://nothingmuch.woobling.org/cpan for more info.
Yuval Kogman <nothingmuch@woobling.org>
Copyright (c) 2007 Yuval Kogman. All rights reserved This program is free software; you can redistribute it and/or modify it under the terms of the MIT license or the same terms as Perl itself.
To install Catalyst::Controller::LeakTracker, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Catalyst::Controller::LeakTracker
CPAN shell
perl -MCPAN -e shell install Catalyst::Controller::LeakTracker
For more information on module installation, please visit the detailed CPAN module installation guide.