[Catalyst] TheSchwartz - Catalyst::Model::Adaptor

gordon at gorste.plus.com gordon at gorste.plus.com
Sat Aug 7 16:26:21 GMT 2010

Dear List.

I am writing a job queuing system in catalyst.  I have found an example of
a job queuing examples that uses TheSchwartz and catalyst through
Catalyst::Model::Adaptor.  Currently it uses Sqlite,  I need to use MySQL,
for me to do this I need to create TheSchwartz with augments like

use parent "Catalyst::Model::Adaptor";

__PACKAGE__->config( class => "TheSchwartz",
                     args => { verbose => 1,

                               databases => [{
                                             'dsn' => 'dbi:mysql:Schwart',
                                             'user' => 'db_user',
                                            ‘pass’ => ‘password’

I just get the following when I run the server:

Couldn't instantiate component "MyApp::Model::TheSchwartz", "unknown
options HASH(0x3a71a30) at
/usr/local/share/perl/5.8.8/Catalyst/Model/Adaptor/Base.pm line
27"Compilation failed in require at ./script/myapp_server.pl line 66.

Does anyone know of how I can fix this?

Once I get this working I will move it to prepare_arguments so that I can
get details out of the config file.



More information about the Catalyst mailing list