[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl-WebCGI] Multitasking?



At 9:31 AM +0100 7/31/00, Stephen Criddle wrote:
>I'm in the midst of redesigining our intranet site.  It runs Macperl and
>Webstar 4.2.  I have a couple of questions about MacPerl and
>multitasking, which will influence the way I write some of the core
>modules.
>
>Does MacPerl run more than one script at the same time?

No.

>
>Does MacPerl run more than one instance of the same script at the same
>time?

No.

>
>I ask these two questions because if the answer is no to both, it makes
>life a lot easier when it comes to record locking and so on.

Maybe, maybe not.  The fact that MacPerl CGIs can only do one thing 
at a time, and the fact that they can respond gracelessly to a 
request by the Web Server to do so, can create significant problems. 
I described this in my column for PerlMonth:

http://www.perlmonth.com/columns/mac_perl/mac_perl.html?issue=11

You may (or may not) have even more trouble than I indicated because 
of your choice of Web Server software (Webstar).  This has to do with 
how the Web Server software responds to the naming of the CGI, 
whether you give it the .cgi or .acgi suffix.  In the original 
discussion of MacPerl CGIs in "MacPerl: Power and Ease", the 
suggestion was to use .acgi, because if you use .cgi, the webserver 
will stop serving anything (including static HTML) to anyone while it 
awaits the response from your CGI.  (This recommendation has been 
modified in the errata.)  My article was based on Quid Pro Quo which 
does not have that behavior.  However, use of .acgi causes problems 
ranging from dropped hits to server crashes with all servers of which 
I am aware.  Thus, when using Quid Pro Quo the choice is clear: use 
the .cgi extension (and take other precautions described in my 
article).  With WebStar, you may pay a price for doing that.

I would actually appreciate it very much if you could experiment with 
WebStar 4.2 and tell me what its behavior is.  If you are willing to 
do this, I can email you some test scripts.

Best of luck!

-David Steffen-
David Steffen, Ph.D.
President, Biomedical Computing, Inc. <http://www.biomedcomp.com/>
Phone: (713) 610-9770 FAX: (713) 610-9769 E-mail: steffen@biomedcomp.com

==== Want to unsubscribe from this list?
==== Send mail with body "unsubscribe" to macperl-webcgi-request@macperl.org