Re: Are global variables truly global?

2001-11-05 Thread Dominique Quatravaux
I have some state data that I need to persist between requests. At the moment these are COM objects, but they'll be ported to Perl Classes. It is quite important that only one of these instances exist per web server. These instances are too large to write and read to file on every request.

RE: Are global variables truly global?

2001-11-05 Thread Matt Sergeant
-Original Message- From: Chui G. Tey [mailto:[EMAIL PROTECTED]] package Apache::MyPkg; my $COM_instance; sub handler { if (!$COM_instance) { $COM_instance = Win32::OLE-new(ProgID.Class); } } Will the different child processes created by Apache share the

Are global variables truly global?

2001-11-04 Thread Chui G. Tey
I have some state data that I need to persist between requests. At the moment these are COM objects, but they'll be ported to Perl Classes. It is quite important that only one of these instances exist per web server. These instances are too large to write and read to file on every request. So I

Re: Are global variables truly global?

2001-11-04 Thread Steven Lembark
-- Chui G. Tey [EMAIL PROTECTED] I have some state data that I need to persist between requests. At the moment these are COM objects, but they'll be ported to Perl Classes. It is quite important that only one of these instances exist per web server. These instances are too large to write

Re: Are global variables truly global?

2001-11-04 Thread Perrin Harkins
Will the different child processes created by Apache share the same variable? Or will each child create an additional instance? Each child has a separate interpreter and thus a separate instance of your global. If you need to co-ordinate data between processes, you might want to look at