Philip Mak wrote:
>
> I have a script that takes 3 seconds to execute; I'm trying to figure out
> how to make it faster. Here are some facts:
>
> 1. I put $s::starttime = [gettimeofday] (that's a function from
> Time::HiRes) at the beginning of Script_OnStart. Then I put statements at
> various places in my script to print how much time has elapsed. It claims
> that 0.02 seconds have elapsed at the end of the script, but it took me 3
> seconds to load the script.
>
> 2. If I reload the script a few times, then it starts responding
> instantaneously, so I'm guessing that something needs to be pre-compiled.
>
> 3. I have "use"d all the modules in startup.pl, and I also call
> Apache::ASP->Loader there:
>
> Apache::ASP->Loader($WEB, '\.(asp|inc|asa)$', Global => $GLOBAL);
>
> Did I miss some pre-compilation step somewhere?
>
Can you show a trace in the error_log with Debug set to -3 ?
Make sure Time::HiRes is installed first. The first request
error_log set from an apache restart would be helpful to see.
It may be that upon global.asa compilation, other modules
get also loaded that were not use'd in startup.pl? We'll
see more with your trace.
I am sure you have, but are you sure startup.pl is running?
You have to PerlRequire it explicitly.
--Josh
_________________________________________________________________
Joshua Chamas Chamas Enterprises Inc.
NodeWorks Founder Huntington Beach, CA USA
http://www.nodeworks.com 1-714-625-4051
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]