From 8c8916c5b7a2afdb5dcb5cc88b4e1d28fe8a5acc Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Tue, 24 Oct 2017 18:55:45 +0000 Subject: doc/queues.txt: add key point about only retrieving ONE event This had become such second nature to me that I forgot to document it :x --- doc/queues.txt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/doc/queues.txt b/doc/queues.txt index d1de9da..fe8c3bb 100644 --- a/doc/queues.txt +++ b/doc/queues.txt @@ -50,8 +50,9 @@ This is either an epoll(2) or kqueue(2) descriptor. Unlike traditional poll(2)/select(2), epoll/kqueue easily allows clients to migrate between threads as client sockets become ready. -To implement queue-like behavior, we rely exclusively on one-shot -notifications (EPOLLONESHOT or EV_ONESHOT). +To implement this behavior, we rely exclusively on one-shot notifications +(EPOLLONESHOT or EV_ONESHOT) and only retrieve one event at-a-time with +epoll_wait or kqueue to avoid head-of-line blocking. active queue ============ -- cgit v1.2.3-24-ge0c7