//btw
接受连接的过程
do {
-Wait for a previous AcceptEx to complete
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-Create a new socket and associate it with the completion port
-Allocate context structure etc.
-Post an AcceptEx request.
}while(TRUE);
to mess:
相当于:one thread per client 模式
不过对于很大数量的连接,如果有1000个客户,开一千个线程显然不是个好主意,所以用completion ports,我的程序已经做完了,还没做负载测试,但感觉确实比one thread per client 更好,特别是资源耗用。