Re: [Libevent-users] question about poll()

2009-12-01 Thread Patrick C
As Nick said, the libevent source itself is a great example of abstracting poll() functionality on multiple platforms, using the locally optimized methods of epoll, kqueue, etc depending on the operating system. This is primarily designed for high-performance network daemons (and sometimes clients)

Re: [Libevent-users] Handling concurent evhttp connections with evhttp_send_reply_chunk.

2009-11-18 Thread Patrick C
I wouldn't use them for sending large files. Use the good 'ole fashion event_* interfaces for checking when a socket needs more data, and use sendfile() to send the data down the socket when it needs it. No reason to have libevent buffers on top of things for this purpose. You have basically the s

Re: [Libevent-users] Handling concurent evhttp connections with evhttp_send_reply_chunk.

2009-11-16 Thread Patrick C
Agreed. The most optimal way of doing this would be to use your operating system's sendfile() routine, where available, in the evhttp_write_cb routine. -Patrick 2009/11/16 Tero Marttila > Krzysztof Adamski wrote: > >> Hi, >> i would like to build simple HTTPD server using libevent2. It is going