Hi Roger, hi Jeff,

Roger wrote:
>
>See this for more information, but don't ask me if it's working.
>
>http://svn.zope.org/zope3org/trunk/src/zorg/live/README.txt?rev=66712&view=markup
>
It works at least for our purposes. We are using an experimental LivePage
application here at our institute. "Experimental" means that 4 subjects of
a psychological study share a message board via browser live pages.

Jeff Rush wrote:
>
>(1) a piece of Javascript downloaded with a page request turns around and 
>issues an HTTP GET back to Zope3 such that that connection is kept open 
>indefinitely, and the thread within Zope3 that is servicing that request
>hangs 
>around and periodically shoves bits of data (XML, JSON, whatever) down
>that 
>pipe that get acted upon by Javascript within the client's page.  This 
>provides server => client communications via a brief REQUEST and a
>neverending 
>RESPONSE chunked up into pieces representing operations run on the client.
>
>(2) another piece of Javascript downloaded with a page request similarly
>turns 
>around and issues an HTTP GET/PUT back to Zope3 with a header to keep the 
>connection open.  Over this pipe the client can issue conventional
>multiple 
>REQUEST/RESPONSE cycles to invoke functions within the server, providing 
>client => server communications.  However the trick re Zope3 is that the 
>URL/view to which that request connects must be one that can rendevous
>with 
>the thread or a piece of state associated with (1) above, so that the
>server 
>and client have a meaningful basis on which to talk.

I struggled with both problems in the zorg.live package. 

(1) In this package I implemented a specialization of the twisted server
which handles LivePage requests outside Zope's threads. Otherwise the
number of connected clients would have been limited to the number of Zope
threads which come with their own object caches and database connections,
in my view an unnecessary overhead for most LivePage requests.

(2) Each client is registered on the server side in a thread safe global
utility. This utility handles the clients ids which are send as parameters
of each LivePage request.

Feel free to contact me if this looks interesting to you.

Regards,
Uwe
________________________________________________________________
Dr. Uwe Oestermeier
Institut für Wissensmedien
Knowledge Media Research Center
Konrad-Adenauer-Str. 40
D-72072 Tuebingen
Germany
[EMAIL PROTECTED]
Tel. +49 7071 979-208
Fax +49 7071 979-100



_______________________________________________
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com

Reply via email to