[Twisted-Python] Use of twisted as web app core
snacktime at gmail.com
Fri Feb 11 12:55:38 EST 2005
On Fri, 11 Feb 2005 18:11:53 +0200, Tommi Virtanen <tv at twistedmatrix.com> wrote:
> Ben.Young at risk.sungard.com wrote:
> > fastcgi communicates by using the stdio stream as a socket. Is there a way
> > in twisted of treating a fd number as is it were a socket?
> > Has anyone used spread with twisted? I think you can use select to see if
> > there is a message waiting, but then you have to use the spread api to
> > actually access the message.
> That is unlikely to work, unless spread actually does non-blocking reads
> and is happy to receive messages in multiple reads.
What about just running the spread client via deferToThread and
schedule how often it runs with LoopingCall? The callback could set
some stateful variables based on the results.
More information about the Twisted-Python