<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class='hmmessage'>To me it sounds like 'Handled' is the flush-and-end helper function to 'Detached'?<BR><BR>
I guess the best example is the "long poll" of the LL http polling queue, where every request is specified to be 'held' for a time interval, so that the server can add events over a time.<BR>
 <BR>
And, on that note : one of the problems we see and will see even more, is that http requests that are taken from the thread pool helps to exhaust the pool.<BR>
 <BR>
If we had some declarative way of stating 'this handler has the potential to be long running' meaning it will get a new thread allocated, that would probably be a good idea.<BR>
 <BR>
(Or the http handler has an internal private thread pool)<BR>
<BR>Best regards,<BR>Stefan Andersson<BR>Tribal Media AB<BR> <BR>Join the 3d web revolution : <A href="http://tribalnet.se/" target=_blank>http://tribalnet.se/</A><BR> <BR><BR><BR><BR>

<HR id=stopSpelling>
<BR>
> Date: Thu, 29 May 2008 09:52:54 +0200<BR>> From: DrScofield@xyzzyxyzzy.net<BR>> To: opensim-dev@lists.berlios.de<BR>> Subject: Re: [Opensim-dev] HttpServer overview & RFC<BR>> <BR>> Dr Scofield wrote:<BR>> > Sean Dague wrote:<BR>> > <BR>> >> On Wed, May 28, 2008 at 08:07:23AM +0200, Dr Scofield wrote:<BR>> >> <BR>> >> <BR>> >>> hi all, another request for comments :-)<BR>> >>> <BR>> >>> <BR>> >> First, +1 on the approach here. A couple of questions / comments in<BR>> >> line just to educate myself.<BR>> >><BR>> >> [...]<BR>> >> [...]<BR>> >> <BR>> >>> == making use of HttpServer ==<BR>> >>> what i'd actually like to implement (either as an HttpModule or as an<BR>> >>> HttpListener handler) is an event--event handler scheme:<BR>> >>> * incoming HTTP request is pushed as an OSHttpRequest object into an<BR>> >>> HTTP request queue.<BR>> >>> * each OSHttpRequest encapsulates<BR>> >>><BR>> >>> * the HTTP request header,<BR>> >>> * an input stream fed by the remote client,<BR>> >>> * an output stream feeding the remote client<BR>> >>> * method to produce OSHttpResponse object (for signaling redirects,<BR>> >>> setting status codes, etc)<BR>> >>><BR>> >>> we have a pool of OSHttpRequest pumps that take OSHttpRequest objects<BR>> >>> and pump them via the registered event handlers to whoever registered<BR>> >>> an interest (via multicast mechanism that stefan already explained a<BR>> >>> couple of days ago as well)<BR>> >>><BR>> >>> event handlers return either<BR>> >>> * Pass --- didn't act on it<BR>> >>> * Handled --- acted on it, response return as out parameter<BR>> >>> * Detach --- acting on it, taking care of it myself, don't do<BR>> >>> anything<BR>> >>> <BR>> >>> <BR>> >> Can you give an example of Handled vs. Detach usage?<BR>> >> <BR>> >> <BR>> > Handled: simple request for an item/an action, no streaming per se <BR>> > involved.<BR>> > Detach: HTTP connection that we keep open; for example, "long poll" <BR>> > support: client connects, requests status update, OpenSim queues the <BR>> > request by detaching the OSHttpRequest from OSHttpServer and placing it <BR>> > in a queue. OSHttpServer happily continues, not sending anything back <BR>> > nor closing the input and output streams. eventually the event the <BR>> > client was interested in occurs, event handler goes through queue of, <BR>> > err, queued OSHttpRequests and responds --- optionally re-queuing the <BR>> > OSHttpRequest.<BR>> > <BR>> another example for detach: streaming media (though can't really think <BR>> of an OpenSim example in that context).<BR>> <BR>> <BR>> -- <BR>> dr dirk husemann ---- virtual worlds research ---- ibm zurich research lab<BR>> SL: dr scofield ---- drscofield@xyzzyxyzzy.net ---- http://xyzzyxyzzy.net/<BR>> RL: hud@zurich.ibm.com - +41 44 724 8573 - http://www.zurich.ibm.com/~hud/<BR>> <BR>> _______________________________________________<BR>> Opensim-dev mailing list<BR>> Opensim-dev@lists.berlios.de<BR>> https://lists.berlios.de/mailman/listinfo/opensim-dev<BR><BR></body>
</html>