[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [Libevent-users] Proposal for libevent-2 to provide functions to hide event structure details
Hi, Pavel! Thanks for the quick response; I will try to add the APIs
in question some time this week.
On Sat, Jan 16, 2010 at 9:12 PM, Pavel Pisa <ppisa4lists@xxxxxxxxxx> wrote:
> Hello Nick,
>
> On Saturday 16 January 2010 06:49:02 Nick Mathewson wrote:
[...]
> As for timeouts, I am sure if it changed for libevent-2, but according
> to my reading libevent-1 did not re-trigger/restart timeout counting
> when there are some data exchanged. My API expect yet opposite case.
In Libevent 2.0, if an event is persistent, then its timeout starts
over whenever the event is triggered. So persistent events with
timeouts are probably what you want here.
> I would like a much to have function to restart timeout or even change
> event timeout triggering time without need of event_del event_add sequence.
> Because these operations means relatively costly operations for some
> mechanisms cases (epoll for example).
Well, that has never been necessary: re-adding an already added event
will reset its timeout without touching the FD layer.
> It is not necessary to manipulate by epoll/FD for these cases, it is enough
> to delete and insert timeout into timers queue/RB-tree.
(It's actually been a minheap since 1.4.x)
--
Nick
***********************************************************************
To unsubscribe, send an e-mail to majordomo@xxxxxxxxxxxxx with
unsubscribe libevent-users in the body.