[Twisted-web] Twisted to proxy php out to apache?

Remi C Cool r.cool at smartology.nl
Wed May 24 01:16:07 CDT 2006


Hello fellow twisters,

David Reid suggested that I should ask the twisted.web list for answers
... so here it is.

We have a rather large web app based on xul, xmlrpc (via twisted) and
php (via apache) .... and we would like to get it all (in due time) in
python.

As a first step it would be perfect to let twisted handle php page
requests so that we can use nevow for the upcomming modules and convert
old modules when we have the time to spare.

Some time ago, I  tried to get PHP to run as a CGI from twisted ... that
was so slow that I got timing problems and a non operatable webapp.
BTW ... nothing new on the FCGI for PHP front yet?

My question ... is it possible to pass php page requests from twisted to
apache so I don't suffer the speed loss but still have my app listening
on only one port (for http and xmlrpc) ? So can twisted be a proxy for
php or is this not the recommended way to go?

I know about the reverseproxy stuff .. but if I understand that
correctly, it's about passing requests to twisted from apache or other
server. I would like it to be the other way round .. twisted passes
requests for PHP to apache, receives the processed content and passes
that back to the client. (if that method doesn't have any significant
drawbacks)

- Remi -




More information about the Twisted-web mailing list