No environment vars on first invocation of Perl FastCGI app

Mark Brown (mbrown@OpenMarket.com)
Fri, 17 May 1996 09:26:40 -0400

Message-Id: <199605171326.JAA03804@breckenridge.openmarket.com>
To: bpm@techapp.com
Subject: No environment vars on first invocation of Perl FastCGI app
Date: Fri, 17 May 1996 09:26:40 -0400
From: Mark Brown <mbrown@OpenMarket.com>


    I have a question about the perl5.002 interface.  I have a problem
    with the FIRST invocation of the perl fcgi application. 

This is a known problem that needs to be better documented; it is
explained in the README file as a note for the 1.2.2 kit, dated 15
April 1996.

The work-around is to give the application at least one *initial* 
environment variable.  In the NCSA, Apache and Open Market servers you
do this using the -initial-env option to the AppClass directive.
For instance, in srm.conf you'd say
    
AppClass /usr/local/etc/httpd/fcgi-devel-kit/examples/echo-perl 
-listen-queue-depth 10 -processes 2 -initial-env FOO=XXX

Somehow, having *anything* set in the initial environment enables the
first request to work fine.  A kludge, indeed; if one of the Perl
experts on the list would fix the problem, that would be great for all.

    --mark