Philip Mak wrote:
> 
> I'm experiencing something strange with my installation of Apache::ASP
> (v2.17).
> 
> [Sat Sep  8 02:08:37 2001] [error] [asp] [19575] [debug] Script_OnStart
> [Sat Sep  8 02:08:37 2001] [error] [asp] [19575] [debug] executing
> __ASP__home_pmak_perl_web_edit_aspxINL
> 
> When it works, the error_log has this:
> 
> [Sat Sep  8 02:09:00 2001] [error] [asp] [19574] [debug] Script_OnStart
> [Sat Sep  8 02:09:00 2001] [error] [asp] [19574] [debug] executing Script_OnStart
> 
> Notice that the first excerpt of the error_log does NOT have "executing
> Script_OnStart". Isn't that subroutine supposed to be always executed?
> 
> Here is my httpd.conf:
> 
> PerlSetVar Global /tmp
...
> PerlSetVar GlobalPackage main
> PerlRequire /home/pmak/perl/global/startup.pl
> PerlFreshRestart On
> 

I think your analysis is right, that Script_OnStart is not
always being called, and the reason is that it is not always
being found in the global.asa ... I don't know how it would
work sometimes & not others.  A trace from the error_log 
with Debug set to -1 would help from a fresh apache stop/start
through when the problem occurs.

I get the feeling that something is manipulating the symbol
table in the *main:: package namespace where your GlobalPackage
is set.  It may be that if you change GlobalPackage to 
something else, they you will be safe from that.  I can 
imagine that certain kinds of packages like Apache::StatINC
or Apache::Reload might do these symbol table manipulations,
so try seeing if using those might be the problem too.

Also, try to avoid having multiple global.asa's from multiple
ASP applications having the same global package.  I could easily
see one global.asa's Script_OnStart overriding another 
in the *main package if you have GlobalPackage set to it in each 
case.  With GlobalPackage set, treat the global.asa as a 
perl package of the GlobalPackage name & namespace, so its
kind of like a main.pm, and if you have multiple main.pm's
only bad things will happen.

--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]

Reply via email to