
libevent
The libevent API provides a mechanism to execute a callback function when a specific event occurs on a file descriptor or after a timeout has been reached. Furthermore, libevent also support callbacks due to signals or regular timeouts. libevent is meant to replace the event loop found in event driven network servers.
libevent: Main Page
Jan 8, 2017 · Libevent is an event notification library for developing scalable network servers. The Libevent API provides a mechanism to execute a callback function when a specific event occurs on a file descriptor or after a timeout has been reached.
Fast portable non-blocking network programming with Libevent
Learning Libevent Chapter 0: About this document Chapter 1: A tiny introduction to synchronous non-blocking IO
The Libevent Reference Manual: Preliminaries
A program written using Libevent should work across all the platforms Libevent supports. Even when there is no really good way to do nonblocking IO, Libevent should support the so-so …
Using the built-in HTTP server - libevent
Feb 18, 2024 · The plain network-based Libevent interface is useful if you want to build native applications, but it is increasingly common to develop an application based around the HTTP protocol and a web page that loads, or more commonly dynamically reloads, information.
Setting up the Libevent library
Libevent has a few global settings that are shared across the entire process. These affect the entire library. You must make any changes to these settings before you call any other part of the Libevent library. If you don’t, Libevent could wind up in an inconsistent state.
libevent: event2/event.h File Reference
Prepare an event_base to use a large number of timeouts with the same duration. Libevent's default scheduling algorithm is optimized for having a large number of timeouts with their durations more or less randomly distributed.
A tiny introduction to synchronous non-blocking IO - libevent
Fortunately, the Libevent 2 "bufferevents" interface solves both of these issues: it makes programs much simpler to write, and provides an interface that Libevent can implement efficiently on Windows and on Unix. Here’s our ROT13 server one last time, using the bufferevents API.
Bufferevents: concepts and basics
A socket-based bufferevent uses Libevent’s underlying event mechanism to detect when an underlying network socket is ready for read and/or write operations, and uses underlying network calls (like readv, writev, WSASend, or WSARecv) to transmit and receive data.
Helper functions and types for Libevent
The <event2/util.h> header defines many functions that you might find helpful for implementing portable applications using Libevent. Libevent uses these types and functions internally.