On 10/7/06, Perrin Harkins <[EMAIL PROTECTED]> wrote: > Maybe this will help: http://www.modperlbook.org/html/ch09_05.html
Thanks, I'll try using Apache::DProf as suggested. > How did you determine this? Manually running and timing the queries as output when DBIC_TRACE=1. Switching from running a "$rs->next" loop inside TT to loading the objects inside the controller (through $rs->all). Then I tried using $rs->all inside the template and noticed the time spent in the controller going down and the spent in the end action going up by approximately the same amount as I've timed when manually running the queries. > There are some generic things you can do to speed up TT (use PROCESS > instead of INCLUDE, use the support for constants if you have any, make > sure you are using the template cache), but I'd do a profile sorted by > real time before spending the effort on them. The template cache gives me a performance boost varying from almost 0% to 10% (average 3%). Using PROCESS instead of INCLUDE makes a tiny difference in my case. I'll take a look into using constants, I never knew TT had them. > Does your template do anything that might cause DBIC to fetch more data? Some of them, yes. The ones in question, no - they prefetch everything they need (at least according to DBIC_TRACE there's nothing missing and only one query is issued). -Nilson Santos F. Jr. _______________________________________________ List: [email protected] Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/[email protected]/ Dev site: http://dev.catalyst.perl.org/
