[Zope] Keep-Alive Connections

Matt Ficken mattficken@mail.com
Sun, 18 May 2003 15:41:53 -0500


My product needs to send data to the client, and then later send the
client more data, over the same connection. HTTP/1.1 created
Keep-Alive connections for this reason. I tried setting the response
header 'Connection' to 'Keep-Alive', but Zope closes the connection
anyway.

So, I made an infinite loop in the function that is called when the
connection is first opened, which keeps the connection open. Within
the loop, the sleep function is called to sleep for 1 second,
otherwise Zope sucks up all my unused CPU cycles.

But, after I get 2 or 3 of these loops going, the whole Zope server
locks up. It won't accept any connections.

Is there a different way I can keep connections alive without locking
up Zope or using all the system's CPU cycles?
-- 
__________________________________________________________
Sign-up for your own FREE Personalized E-mail at Mail.com
http://www.mail.com/?sr=signup