Bugzilla – Attachment 7589 Details for
Bug 7511
Caching Templates
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 7511 [ENH] Template caching (T::T feature)
Bug-7511-ENH-Template-caching-TT-feature.patch (text/plain), 1.66 KB, created by
Jared Camins-Esakov
on 2012-02-12 19:31:02 UTC
(
hide
)
Description:
Bug 7511 [ENH] Template caching (T::T feature)
Filename:
MIME Type:
Creator:
Jared Camins-Esakov
Created:
2012-02-12 19:31:02 UTC
Size:
1.66 KB
patch
obsolete
>From 252e40938c0fea34cfcc9df05ba0cf1e7845253d Mon Sep 17 00:00:00 2001 >From: Paul Poulain <paul.poulain@biblibre.com> >Date: Fri, 10 Feb 2012 09:45:34 +0100 >Subject: [PATCH] Bug 7511 [ENH] Template caching (T::T feature) >Content-Type: text/plain; charset="UTF-8" > >Just add to your Koha configuration file ><template_cache_dir>/path/writable/by/apache/user</template_cache_dir> >in the <config> block, and Koha will use template caching, for about >10% CPU time saving. > >on linux servers, /tmp is usually OK > >(also fixes an indenting with a TAB) > >Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com> >The results of using this are very striking. Based on an insufficient >sample size, it would seem that the time spent in T::T is reduced by a >factor of at least 5. >--- > C4/Templates.pm | 5 +++-- > 1 files changed, 3 insertions(+), 2 deletions(-) > >diff --git a/C4/Templates.pm b/C4/Templates.pm >index d150a16..0741040 100644 >--- a/C4/Templates.pm >+++ b/C4/Templates.pm >@@ -53,12 +53,13 @@ sub new { > else { > $htdocs = C4::Context->config('intrahtdocs'); > } >- > my ($theme, $lang)= themelanguage( $htdocs, $tmplbase, $interface, $query); > my $template = Template->new( > { EVAL_PERL => 1, > ABSOLUTE => 1, >- PLUGIN_BASE => 'Koha::Template::Plugin', >+ PLUGIN_BASE => 'Koha::Template::Plugin', >+ COMPILE_EXT => C4::Context->config('template_cache_dir')?'.ttc':'', >+ COMPILE_DIR => C4::Context->config('template_cache_dir')?C4::Context->config('template_cache_dir'):'',, > INCLUDE_PATH => [ > "$htdocs/$theme/$lang/includes", > "$htdocs/$theme/en/includes" >-- >1.7.2.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 7511
:
7558
| 7589