"Schwab,Wilhelm K" <bschwab@anest.ufl.edu> ... The question then becomes whether to connect to OpenSSL via FFI/Alien or to make a plugin. Â One absolute requirement is that the image not turn to stone when an address is wrong, a peer crashes, or a router gets unplugged w/o warning. Â The most obvious solution to me (please speak up if you disagree) is to connect/bind, read/write and disconnect on a connection-specific OS thread.
I would think a separate thread (or process) is required to handle and recover from bad pointer references. For general client/server multiplexing however, you might look at liboop for ideas: http://liboop.ofb.net/ "Liboop is a low-level event loop management library for POSIX-based operating systems. It supports the development of modular, multiplexed applications which may respond to events from several sources. It replaces the "select() loop" and allows the registration of event handlers for file and network I/O, timers and signals. Since processes use these mechanisms for almost all external communication, liboop can be used as the basis for almost any application." There are refs to other event dispatchers on the liboop web page. FYI, -KenD