Boost.Asio has following main features:
- ability to write cross-platform networking code, working on the most of existing platforms - Windows, Unix-like, Tru64, QNX, etc..
- supports both IPv4 and IPv6
- support for TCP & UDP
- support for asynchronous operations
- provide std::iostream compatible interfaces
- support for SSL connections
- support for delayed operations (timers)
For demonstration of Boost.Asio's features i wrote (some of parts was adopted from Boost.Asio examples) several examples, implementing different data handling strategies (more examples could be found on the home page of Boost.Asio). I had used these examples for selecting appropriate data handling strategies for my own applications. All these examples implements "stupid" web-server, that read request and return back single page, independent on address, that was specified in request. Currently published following examples (all sources include file common.h):
- test-mcmt.cpp - implements data handling strategy Many Connections/Many Threads - it run several threads, each of them accept connections and perform input/output in async mode;
- test-otpc.cpp - implements strategy One Thread per Connection - one thread accepts connections in async mode, and than run thread, in which input/output performed in sync mode (code, performing this is in files test-otpc-conn.cpp & test-otpc-conn.hpp);
- test-otpc-tp.cpp - almost same as test-otpc.cpp, but instead of dedicated thread for every connection, used pool of threads, implemented by threadpool library
I think, that on the base of this note it will possible to write more complete article, but this is future task, but now you can ask me about boost.asio directly :-)