<div><br><div class="gmail_quote">On Mon, Mar 2, 2009 at 11:49 AM, Hans Hübner <span dir="ltr"><<a href="mailto:hans.huebner@gmail.com">hans.huebner@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="Ih2E3d">On Sat, Feb 28, 2009 at 14:01, Slawek Zak <<a href="mailto:slawek.zak@gmail.com">slawek.zak@gmail.com</a>> wrote:<br>
> On Fri, Feb 27, 2009 at 5:14 PM, Hans Hübner <<a href="mailto:hans.huebner@gmail.com">hans.huebner@gmail.com</a>> wrote:<br>
</div><div class="Ih2E3d">>> Yes, a specialized COMET handling system would be possible. It may<br>
>> make sense to use a specialized task master so that connections which<br>
>> are waiting on a server-side event do not tie up a worker thread.  The<br>
>> new taskmaster/acceptor architecture is meant to support that.<br>
><br>
> I see a bit of a problem with that API for this purpose. One would want to<br>
> somehow distinguish between comet and non-commet calls. To do this you would<br>
> have to inspect URI or method of the request to spawn a thread or pass the<br>
> request to dedicated comet handler for example.<br>
<br>
</div>Wouldn't you be able to write a task manager that first reads the<br>
request header, then decides whether the request is a COMET request<br>
and queue it or hand it over to another thread for processing?  You<br>
might still want to have multiple connection handling threads in order<br>
to have some concurrency in request header reading, but such a scheme<br>
should be possible with the current architecture.  Or am I missing<br>
something?</blockquote><div> </div></div></div><div>It is possible, but handle-incomming-connection is now in fact a thin wrapper around <span class="Apple-style-span" style="border-collapse: collapse; ">process-connection which does all the work, thus having process management depend on request contents requires one to patch or rewrite process-connection to simply avoid reading request data which have been read already.</span><div>
<span class="Apple-style-span" style="border-collapse: collapse; "><br></span></div><div><span class="Apple-style-span" style="border-collapse: collapse; ">/S<br></span></div></div>