BSD kqueue: A Mountain of Technical Debt

2024-12-29

This article delves into the differences between BSD kqueue and Linux epoll in network programming. kqueue uses event filters, offering powerful functionality but lacking composability, leading to accumulating technical debt. Epoll, on the other hand, directly manipulates kernel handles, boasting greater composability and allowing for flexible monitoring of various kernel resources such as sockets, filesystem paths, and timers. The author argues that epoll's design is superior as it avoids the predicament of constantly adding new event filter types to kqueue with each new feature.

Read more
Development network programming