Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update design doc #143

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

dingweiqings
Copy link

@dingweiqings dingweiqings commented Sep 9, 2022

Description

After I read your good code and try to understand your design , I add some notes in your design md doc and fix some typos. This PR is for this .

Change File

并发模型.md

@hbzzhtt
Copy link

hbzzhtt commented Jul 9, 2023

You've added too many redundant files, like CMakeFiles , Makefile, xxx.log .....

WebServer/Main.cpp Outdated Show resolved Hide resolved
build.sh Outdated Show resolved Hide resolved
@dingweiqings dingweiqings force-pushed the topic/kurt.ding/update-design-doc branch from 81d3b98 to 9a1cc1c Compare July 20, 2023 06:43
并发模型.md Outdated

程序中的每一个类和结构体当然都必不可少,其中能体现并发模型和整体架构的,我认为是有下面几个类:
#### Server类
Server是http服务器的包装类,主要负责开启端口监听和启动事件主循环(Main Reactor),其中事件主循环会将新的客户端连接accept,并放入epoll监控的fd队列,交由后面EventLoop(Sub Reactor)来和客户端做socket读写通信(借助于Channel类)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one thread one loop 的含义更多是 one thread one reactor,这里可以着重介绍一下Server是如何组织多个reactor,如何分配事件到相应的reactor之中的,这个过程更能体现整体结构和并发来源

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

updated

@wk-night
Copy link

请问一下能给HttpData文件解释一下吗,有些搞不明白这个文件的作用

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants