http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15341
--- Comment #1 from Jonathan Druart <[email protected]> --- Created attachment 45535 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=45535&action=edit Bug 15341: Retrieve all sysprefs at once C4::Context->preference generates a call to Koha::Config::SysPrefs->find for all different sysprefs we are searching for. It seems to be a performance killer and be better to retrieve them all together. I have enabled general_log in the MariaDB config file, the GET circ/circulation.pl?borrowernumber=42 There are 293 queries of the following form: SELECT me.variable, me.value, me.options, me.explanation, me.type FROM systempreferences me WHERE ( me.variable = 'MY_SYSPREF' ) Then benchmarking before and after this patch (using plackup, and the misc/plack/koha.psgi file with Profiler::NYTProf enabled): Before: Profile of /home/koha/perl5/bin/plackup for -2.07s (of 616ms), executing 158857 statements and 588479 subroutine calls in 427 source files and 73 string evals. 885 174ms 4.03s C4::Context::preference After: Profile of /home/koha/perl5/bin/plackup for -1.70s (of 349ms), executing 94273 statements and 397525 subroutine calls in 437 source files and 79 string evals. 1138 194ms 1.99s C4::Context::preference (calls) (exclusive time) (inclusive time) Could someone confirm that? -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
