From:             james at grickel dot org
Operating system: 
PHP version:      Irrelevant
PHP Bug Type:     Feature/Change Request
Bug description:  True FastCGI support

Description:
------------
Currently PHP's FastCGI's code just keeps php loaded while the script is
executed over and over every time.

I'm proposing a system where fastcgi could be natively used by the php
script. Like how fastcgi is used in perl, or C.

The code could possibly look something like this:
------------------
#!/usr/bin/php-fastcgi
<?php
do_init();
while(fastcgi_next_request() != null) {
    do_request_stuff();
}
do_shutdown();
?>
------------------

This would allow large scripts that load lots of data to keep them loaded
and serve many requests.

This would be very advantagous for performance. The script itself would
look like a fastcgi script to the server. Not the php executable. So you
wouldn't be able to use the apache Action directive. You'd just need to
have the hash-bang in every php file.

I'm not familiar enough with php's sapi, nor fastcgi. But from what I know
it should be possible if you don't use treat the php _script_ as a cgi and
use the hash-bang on every file.

Thanks,
James Harr


-- 
Edit bug report at http://bugs.php.net/?id=24590&edit=1
-- 
Try a CVS snapshot (php4):  http://bugs.php.net/fix.php?id=24590&r=trysnapshot4
Try a CVS snapshot (php5):  http://bugs.php.net/fix.php?id=24590&r=trysnapshot5
Fixed in CVS:               http://bugs.php.net/fix.php?id=24590&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=24590&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=24590&r=needtrace
Try newer version:          http://bugs.php.net/fix.php?id=24590&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=24590&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=24590&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=24590&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=24590&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=24590&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=24590&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=24590&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=24590&r=isapi
Install GNU Sed:            http://bugs.php.net/fix.php?id=24590&r=gnused

Reply via email to