[Dbix-class] Startup times for DBIX::Class

Matija Grabnar matija at literal.si
Thu Jul 6 20:15:42 CEST 2006


I am concerned about the time it takes DBIx::Class to initialize with a 
moderate sized database
(around 30 tables). It looks like it takes about half a second per table 
- even though all the data
about the tables has been gathered by sql translator.

That makes it impossible to use DBIx::Class in a regular CGI (yes, 
sometimes I have to deploy
stuff without mod_perl or fastcgi, like when a customer has their 
servers managed by a third party that refuses to install either).

I'm attaching the schema file, the script (the script itself is very 
simple) and the printout of the times
where you can see how long it takes to process each part of the script 
and schema definition.

Is there ANY way to speed up the startup? Is DBIx::Class scanning the 
tables for each declaration? Is it possible to turn that off somehow?

FindBin 1152208991.07711
use lib 1152208991.10095
use DbMail 1152208991.11096
dbmail_messageblks 1152208991.46195
dbmail_aliases 1152208991.98519
msgrcpt 1152208992.03513
maddr 1152208992.1098
dbmail_sievescripts 1152208992.17705
users 1152208992.26129
dbmail_usermap 1152208992.36602
dbmail_tofield 1152208992.47261
dbmail_mailaddr 1152208992.6035
dbmail_referencesfield 1152208992.74111
dbmail_auto_replies 1152208992.90496
dbmail_users 1152208993.07558
quarantine 1152208993.25146
policy 1152208993.43448
dbmail_pbsp 1152208993.66644
dbmail_datefield 1152208993.88641
dbmail_subjectfield 1152208994.1299
dbmail_replytofield 1152208994.38021
dbmail_fromfield 1152208994.6494
dbmail_subscription 1152208994.92376
dbmail_auto_notifications 1152208995.22363
dbmail_wblist 1152208995.52099
dbmail_messages 1152208995.85729
dbmail_s 1152208996.20095
dbmail_mailboxes 1152208996.54097
dbmail_msgs 1152208996.91973
dbmail_headervalue 1152208997.54039
dbmail_ccfield 1152208997.93119
dbmail_headername 1152208998.33687
dbmail_acl 1152208998.74704
dbmail_physmessage 1152208999.17965
dbmail_filters 1152208999.62672
register classes 1152209000.08107
processing 1152209000.08494

-------------- next part --------------
A non-text attachment was scrubbed...
Name: DbMail.pm
Type: text/x-perl
Size: 56277 bytes
Desc: not available
Url : http://lists.rawmode.org/pipermail/dbix-class/attachments/20060706/7b874f45/attachment-0001.pm 
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: dbmail_quotareport
Url: http://lists.rawmode.org/pipermail/dbix-class/attachments/20060706/7b874f45/attachment-0001.diff 


More information about the Dbix-class mailing list