https://github.com/zhaocc1106/linux_server_programming
linux高性能服务器编程
https://github.com/zhaocc1106/linux_server_programming
hpp libevent reactive-server
Last synced: 2 months ago
JSON representation
linux高性能服务器编程
- Host: GitHub
- URL: https://github.com/zhaocc1106/linux_server_programming
- Owner: zhaocc1106
- Created: 2020-10-30T01:38:47.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2020-11-19T12:27:13.000Z (over 4 years ago)
- Last Synced: 2023-03-10T12:16:35.929Z (about 2 years ago)
- Topics: hpp, libevent, reactive-server
- Language: C++
- Homepage:
- Size: 90.8 KB
- Stars: 2
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# linux_server_programming
linux服务器编程## server
[tools.hpp](https://github.com/zhaocc1106/linux_server_programming/blob/main/server/include/tools.hpp):常用工具,例如进程守护化方法。
[thread_safe_queue.hpp](https://github.com/zhaocc1106/linux_server_programming/blob/main/server/include/thread_safe_queue.hpp):多线程安全队列。
[simple_tcp_server.hpp](https://github.com/zhaocc1106/linux_server_programming/blob/main/server/include/simple_tcp_server.hpp):简单的tcp server,回顾常用的socket api,以及socket创建,监听,接受,读写。
[simple_file_down_server.hpp](https://github.com/zhaocc1106/linux_server_programming/blob/main/server/include/simple_file_down_server.hpp):一个简单的文件下载服务器,使用sendfile函数实现零拷贝(用户空间和内核空间)。
[multi_connection_server.hpp](https://github.com/zhaocc1106/linux_server_programming/blob/main/server/include/multi_connection_server.hpp):使用select,poll,epoll(et与lt触发模式,并且reactor I/O模型将任务放到分发线程池中提升并发)多路复用机制实现支持多客户端连接的服务器。
[libev_multi_con_server.hpp](https://github.com/zhaocc1106/linux_server_programming/blob/main/server/include/libev_multi_con_server.hpp):使用libevent事件驱动和单线程实现支持多客户端连接的服务器。
[libev_half_sync_reactive_thread_pool_server.hpp](https://github.com/zhaocc1106/linux_server_programming/blob/main/server/include/libev_half_sync_reactive_thread_pool_server.hpp):使用libevent事件驱动 + half-sync/half-reactive事件处理模式 + 线程池实现高速处理多请求的server。
[epoll_half_sync_reactive_proc_pool_server.hpp](https://github.com/zhaocc1106/linux_server_programming/blob/main/server/include/epoll_half_sync_reactive_proc_pool_server.hpp):使用epoll多路复用 + half-sync/half-reactive事件处理模式 + 进程池实现及时处理多请求的server。## client
[simple_tcp_client.hpp](https://github.com/zhaocc1106/linux_server_programming/blob/main/client/include/simple_tcp_client.hpp):简单的tcp client,回顾常用的socket api,以及socket创建,连接,读写。
[libevent_no_block_client.hpp](https://github.com/zhaocc1106/linux_server_programming/blob/main/client/include/libevent_no_block_client.hpp):使用libevent事件驱动实现非阻塞多客户端请求。