trafficserver-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bryan Call <bc...@yahoo-inc.com>
Subject Re: Polling Library
Date Fri, 30 Oct 2009 22:55:13 GMT
I wonder how the thread support is.  I think having a wrapper class so 
we can plugin different event handlers might be helpful.

I see a lot of projects handling epoll/kqueue directly.  Not saying this 
is ideal, I just wonder why there hasn't been the uptake in using event 
libraries.

-Bryan

On 10/30/2009 02:46 PM, Paul Querna wrote:
> Hi,
>
> I think we need to use some kind of library to abstract IO polling,
> rather than completely reinventing the wheel.
>
> Lief mentioned possibly using libev:
> <http://software.schmorp.de/pkg/libev.html>
>
> I took a quick look at the internals of libev, and they seemed mostly
> sane.  It uses callbacks, instead of exposing arrays of results to the
> library user.
>
> The callback approach is also what APR/httpd is moving to with the
> newest apr_pollcb API, and what the new Simple MPM was designed around
> -- the callbacks do introduce a a frame jump, but they mean you can be
> portable, and only iterate the result set of events once.
>
> Alternatives would include using libevent, or rolling our own.
>
> I am personally in favor of using libev.
>
> Thoughts?
>
> Thanks,
>
> Paul
>    



Mime
View raw message