franktea / network

asio examples

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

network

学习asio的最多、最全、最有用、最容易学会的例子,功能和实现方式与asio的例子尽量不一样。

2022-09-30 master已经升级到c++20,并且只支持c++20,如果不能使用C++20请取tag v1.0_c++11

git clone https://github.com/franktea/network.git;
cd network;
mkdir -p build;
cd build;
cmake ..;
make

projects

Httpclient is a simple httpclient

httpclient-https is a simple httpclient, with https supported

socks5-daemon is a simple socks5 server implemention

fixed-size-package shows how to send and receive packets of a fixed-length header. Endianness is not considered in the code.

redis-asio is a simple redis client implemention.

io_context example of io_context, shows how to use run/poll/dispatch/post

simplest_httpsvr is trying to make a simplest http svr

custom_errorcode shows how to make custom error_code in asio

custom_timer_manager shows how to make a custom timer manager for asio

protobuf_rpc shows how to implement a simple rpc framework of protobuf 2.x

echo_client async echo client, which is not included in asio examples

asio_libcurl demonstrate how to integrate asio with libcurl, the old example is kinda too old, and has some bugs.

use_awaitable_as_default demonstrate how to eliminate writing use_awaitable everytime.

About

asio examples


Languages

Language:C++ 95.0%Language:CMake 3.0%Language:Makefile 1.9%Language:Python 0.1%Language:C 0.1%