-
Notifications
You must be signed in to change notification settings - Fork 3.5k
Description
We (Envoy; https://github.com/envoyproxy/envoy) would like to start collecting histograms on the epoll (or more generally, event loop) duration. This will help us to identify badly behaving event handlers in extensions to Envoy. In addition, we'd like to track wakeup delay; specifically the time between when the event manager blocks for the next wakeup and when the wakeup occurs, to get an idea of kernel load.
The existing libevent event loop (http://www.wangafu.net/~nickm/libevent-book/Ref3_eventloop.html) doesn't really support this, even if we run with EVLOOP_ONCE.
I'm interested in hearing from libevent folks how we could best add this support; we don't mind taking on this work item but would like some guidance on the best fit to libevent's API. I think libev/libuv could support this with their check/prepare/idle watchers, but maybe there is something lighterweight to add to libevent.
CC @mattklein123
Related discussion in envoyproxy/envoy#4952