2

I have been using perl and ruby in a fcgi setting and was planning to migrate a large code base of php from mod_php to fcgi, I looked at the php site and saw they supported fcgi and 5.3 has fpm to improve the ease of use of fcgi but I was unable to find any examples of the event loop in php - I thought I will look for that later... Well, now it is later and I am freaking out because I assumed fcgi was fcgi then I read this:
http://blog.milkfarmsoft.com/2006/06/fastcgi-in-php-the-way-it-could-be/

"PHP’s fastcgi SAPI doesn’t expose runloop to the PHP application,but implements it inside of itself,instead. As a result,we still have “everything is cleaned up on exit”mode,which leaves us without possibility to pre-init anything."

omfg :(

The site gets several million page views per day and the rewrite to fcgi was supposed to save millions of php and mysql opens/lib set ups and memcache opens, etc.

Is there any way to do "real" fcgi with php? Thanks in advance for any ideas.

Ann E. M.
  • 23
  • 2
  • You could look at [phpdaemon](http://phpdaemon.net/) – zerkms Aug 31 '11 at 03:08
  • Is your question a response to yesterdays ["real fastcgi"](http://stackoverflow.com/questions/7237280/how-to-design-applications-for-persistent-php-fastcgi-processes) discussion? That PHP applications don't interact with the FastCGI API/runloop is just so that PHPs normal processing model isn't corrupted. So there is no actual migration coding for the switch from modphp to fcgi-php. Or do you want to discuss an actual performance need? – mario Aug 31 '11 at 03:12
  • Wow, pure coincidence, I searched for past few days with different keywords but didn't see that discussion - thanks for the link to that discussion. – Ann E. M. Aug 31 '11 at 03:28

0 Answers0