Catalyst::Model::KiokuDB - use KiokuDB in your Catalyst apps
package MyApp::Model::KiokuDB; use Moose; BEGIN { extends qw(Catalyst::Model::KiokuDB) } # this is probably best put in the catalyst config file instead: __PACKAGE__->config( dsn => "bdb:dir=root/db" ); $c->model("kiokudb")->lookup($id);
If true (the default), new_scope will be called once per request automatically.
new_scope
If true (the default) and manage_scope is also enabled, the live object set will be cleared at the end of every request.
manage_scope
This also reports any leaked objects.
Note that in order to work the stash is cleared. Since this is run after $c is already destroyed this should not be an issue, but if it causes problems for you you can disable it.
$c
Under -Debug mode statistics on loaded objects will be printed as well.
-Debug
Defaults to KiokuX::Model.
See KiokuX::Model for more details. This is the proper place to provide convenience methods for your model that are reusable outside of your Catalyst app (e.g. in scripts or model unit tests).
KiokuDB, KiokuX::Model, Catalyst::Authentication::Store::Model::KiokuDB
KiokuDB is maintained using Git. Information about the repository is available on http://www.iinteractive.com/kiokudb/
Yuval Kogman <nothingmuch@woobling.org>
Copyright (c) 2009 Yuval Kogman, Infinity Interactive. All rights reserved This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install Catalyst::Model::KiokuDB, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Catalyst::Model::KiokuDB
CPAN shell
perl -MCPAN -e shell install Catalyst::Model::KiokuDB
For more information on module installation, please visit the detailed CPAN module installation guide.