[Templates] Enabling caching of templates under mod_perl?
Andrew Light
andrewlight7@googlemail.com
Mon, 16 Jul 2007 00:32:50 +0200
------=_Part_79762_12808253.1184538770267
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline
Hi everybody,
i am encountering quite a performance problem with the TT under mod_perl an=
d
would be glad if anyone here could assist.
I am currently running my web-app under mod_perl, but as far as I can see,
none of the dynamic pages, put together using the TT is being chached.
This means: I notice no performance increase, compared to running the sites
on plain old CGI -> everytime I run such a page the whole processing takes
place, which takes a couple of seconds until its done.
Other files, not using the TT, but simply spooling out the HTML, using
regular "print" statements, definitely get a performance boost under
mod_perl, compared to CGI.
So, I have the situation that all my pages going throught the TT are slow
and the ones using "plain old" print spooling are fast.
The processing of the templates takes place, like in the described CGI
exmpales on this site.
To be honest, not knowing much about mod_perl, I don=B4t understand what I
have to change for the mod_perl envirionment.
Is it enough to just use a global variable in each of the calling scripts,
which stores the compiled template? Or would this be a definite "no no".
Thanks for your time and for any input on this question. I would really
appreciate it.
setup: mod_perl2.x, apache 2.x, perl 5.8
------=_Part_79762_12808253.1184538770267
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline
Hi everybody,<br><br>i am encountering quite a performance problem with the=
TT under mod_perl and would be glad if anyone here could assist.<br><br>I =
am currently running my web-app under mod_perl, but as far as I can see, no=
ne of the dynamic pages, put together using the TT is being chached.
<br>This means: I notice no performance increase, compared to running the s=
ites on plain old CGI -> everytime I run such a page the whole processin=
g takes place, which takes a couple of seconds until its done. <br>Other fi=
les, not using the TT, but simply spooling out the HTML, using regular &quo=
t;print" statements, definitely get a performance boost under mod_perl=
, compared to CGI.
<br><br>So, I have the situation that all my pages going throught the TT ar=
e slow and the ones using "plain old" print spooling are fast.<br=
><br>The processing of the templates takes place, like in the described CGI=
exmpales on this site.
<br>To be honest, not knowing much about mod_perl, I don=B4t understand wha=
t I have to change for the mod_perl envirionment.<br>Is it enough to just u=
se a global variable in each of the calling scripts, which stores the compi=
led template? Or would this be a definite "no no".
<br><br>Thanks for your time and for any input on this question. I would re=
ally appreciate it.<br>setup: mod_perl2.x, apache 2.x, perl 5.8<br><br><br>
------=_Part_79762_12808253.1184538770267--