NAME

Catalyst::Plugin::LeakTracker - Use Devel::Events::Objects to track object leaks in the Catalyst request cycle.

SYNOPSIS

package MyApp;

use Catalyst qw/
    LeakTracker
/;

# ...

sub foo : Local {
    my ( $self, $c ) = @_;

    $c->object_trackers
}

DESCRIPTION

This plugin will use Devel::Events::Objects and Devel::Events::Handler::Log::Memory to keep track of objects created in every request. It will also generate events corresponding to the request flow and action execution to facilitate generating stack dumps and more debugging information.

You probably just want to use Catalyst::Controller::LeakTracker to get leak reports.

METHODS

get_all_request_ids

Returns all the request IDs

get_all_request_begin_events

Returns all the request_begin events

get_request_events $request_id

Get all the events that happenned in a given request

get_event_by_id $event_id

Gets the logged event by id

generate_stack_for_event $request_id, $event_id

Returns a Catalyst action stack trace for the event ID

get_object_tracker_by_id $request_id

Returns the object tracker instantiated for the specified request

get_object_entry_by_id $request_id, $event_id

Returns the event entry. This contains the "real" copy of the object, not the stringified version that get_event_by_id would give.

get_object_by_event_id $request_id, $event_id

Like get_object_entry_by_id but returns just the object field.

object_trackers
object_tracker_hash
devel_events_log
devel_events_filters
devel_events_multiplexer
devel_events_generator

These class data accessors contain the various support objects.

create_devel_events_log
create_devel_events_log_filter
create_devel_events_multiplexer
create_devel_events_object_tracker
create_devel_events_object_event_generator
create_devel_events_filter_chain

These methods create the various Devel::Events and Devel::Events::Objects instances.

SEE ALSO

Devel::Events, Devel::Events::Objects, Catalyst::Controller::LeakTracker, http://blog.jrock.us/articles/Plugging%20a%20leaky%20whale.pod

AUTHOR

Yuval Kogman <nothingmuch@woobling.org>

COPYRIGHT & LICENSE

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.