Catalyst Models

Catalyst supports many existing models through pre-built model components available via CPAN. In addition to pre-built models, you can use your own or even choose to not use a Catalyst model.

A Catalyst model is a \MyApp::Model::ModelX module that is used to connect to an external model using configuration information. The model is made available via the context object via $c->model('\ModelX').

For further explanation see Catalyst::Manual::Tutorial.

Selection Overview

Database Models

The most popular models are ones that provide access to a relational database via DBI, either directly or through a higher level ORM.

Catalyst::Model::DBIC::Schema This is the most popular model for Catalyst and is based on DBIx::Class::Schema (aka DBIC::Schema), a \ResultSet-oriented RBDMS-OO layer designed to support access to as much of SQL as possible, including native joins, HAVING and GROUP BY capabilities. It comes with Task::Catalyst and has the most support on the #catalyst IRC channel. Support is also available on the #dbix-class IRC channel. Matt S. Trout (mst) is the primary architect of DBIx::Class and can be found on both #catalyst and #dbix-class.

Catalyst::Model::DBI For raw-DBI access only, Catalyst::Model::DBI is available as a simple and lightweight model. This model is production ready and supports both threading and forking modes as evident in the source code. If you need database handle sharing between models, please refer Catalyst::Model::Proxy. For managing sql statements with separate files, please refer to Catalyst::Model::DBI::SQL::Library.

Fulltext search Models

Catalyst::Model::Plucene Plucene is a Perl port of Lucene, a Java-based fulltext search engine. On #catalyst, Xapian is preferred over Plucene. In particular, Plucene has bad performance due to a massive number of method calls. This design exists due to its mirroring of the Lucene's Java architecture which is much more efficient at handling large numbers of method calls. It's been suggested there are additional hidden bugs as well.

Catalyst::Model::Xapian Xapian is a C++ search library used to power some very large sites.

My tags:
 
Popular tags:
 
Powered by Catalyst
Powered by MojoMojo Hosted by Shadowcat - Managed by Nordaaker