使用完成端口实现IOCP服务器端框架,用于实现高并发服务器

上传者: zhao200011 | 上传时间: 2020-01-04 03:15:15 | 文件大小: 75KB | 文件类型: rar
自己准备实现一个web服务器学习IOCP而封装的一个框架,能适应高并发(默认我设置是64个)连入及多client同时在线传输数据(最大测试到30000).包括TCP与UDP两种协议的IOCP封装实现。比较好的解决了掉线,死机,超时等socket关闭问题及WAIT_TIME问题。同时用较好方式实现了AcceptContext,ReceiveContext,Sendcontext的管理(自己写了个static类),重用各种context,避免频繁的new与delete操作.系统容量会随接入用户自动提升.框架清楚,接口已经做好,写web服务器是很容易的事情了。

文件下载

资源详情

[{"title":"( 40 个子文件 75KB ) 使用完成端口实现IOCP服务器端框架,用于实现高并发服务器","children":[{"title":"IOCP_Server","children":[{"title":"IOCP_Server","children":[{"title":"OperateContext.h <span style='color:#111;'> 792B </span>","children":null,"spread":false},{"title":"BaseDefine.h <span style='color:#111;'> 1.06KB </span>","children":null,"spread":false},{"title":"stdafx.cpp <span style='color:#111;'> 215B </span>","children":null,"spread":false},{"title":"AcceptContext.cpp <span style='color:#111;'> 3.82KB </span>","children":null,"spread":false},{"title":"TcpSendContext.cpp <span style='color:#111;'> 4.05KB </span>","children":null,"spread":false},{"title":"OperateContext.cpp <span style='color:#111;'> 398B </span>","children":null,"spread":false},{"title":"TcpReceiveContext.h <span style='color:#111;'> 1.23KB </span>","children":null,"spread":false},{"title":"stdafx.h <span style='color:#111;'> 195B </span>","children":null,"spread":false},{"title":"TcpSendContext.h <span style='color:#111;'> 1.22KB </span>","children":null,"spread":false},{"title":"AcceptContext.h <span style='color:#111;'> 1.20KB </span>","children":null,"spread":false},{"title":"vssver2.scc <span style='color:#111;'> 1.04KB </span>","children":null,"spread":false},{"title":"TcpSrvException.cpp <span style='color:#111;'> 347B </span>","children":null,"spread":false},{"title":"ContextStack.h <span style='color:#111;'> 544B </span>","children":null,"spread":false},{"title":"TcpReceiveContext.cpp <span style='color:#111;'> 4.20KB </span>","children":null,"spread":false},{"title":"UdpServer.cpp <span style='color:#111;'> 15.49KB </span>","children":null,"spread":false},{"title":"MemoryBlock.h <span style='color:#111;'> 437B </span>","children":null,"spread":false},{"title":"TcpSrvException.h <span style='color:#111;'> 645B </span>","children":null,"spread":false},{"title":"MemoryBlock.cpp <span style='color:#111;'> 409B </span>","children":null,"spread":false},{"title":"IOCP_Server.aps <span style='color:#111;'> 17.13KB </span>","children":null,"spread":false},{"title":"UdpContext.h <span style='color:#111;'> 1.17KB </span>","children":null,"spread":false},{"title":"UdpContext.cpp <span style='color:#111;'> 4.34KB </span>","children":null,"spread":false},{"title":"WebServer.cpp <span style='color:#111;'> 1.03KB </span>","children":null,"spread":false},{"title":"ContextStack.cpp <span style='color:#111;'> 1.15KB </span>","children":null,"spread":false},{"title":"resource.h <span style='color:#111;'> 390B </span>","children":null,"spread":false},{"title":"IOCP_Server.cpp <span style='color:#111;'> 684B </span>","children":null,"spread":false},{"title":"IOCP_Server.vcproj <span style='color:#111;'> 5.32KB </span>","children":null,"spread":false},{"title":"IOCP_Server.rc <span style='color:#111;'> 1.25KB </span>","children":null,"spread":false},{"title":"UdpServer.h <span style='color:#111;'> 1.81KB </span>","children":null,"spread":false},{"title":"mssccprj.scc <span style='color:#111;'> 177B </span>","children":null,"spread":false},{"title":"TcpServer.cpp <span style='color:#111;'> 27.57KB </span>","children":null,"spread":false},{"title":"TcpServer.h <span style='color:#111;'> 2.65KB </span>","children":null,"spread":false},{"title":"WebServer.h <span style='color:#111;'> 302B </span>","children":null,"spread":false},{"title":"IOCP_Server.vcproj.vspscc <span style='color:#111;'> 277B </span>","children":null,"spread":false},{"title":"ReadMe.txt <span style='color:#111;'> 1015B </span>","children":null,"spread":false}],"spread":false},{"title":"IOCP_Server.sln <span style='color:#111;'> 1.37KB </span>","children":null,"spread":false},{"title":"vssver2.scc <span style='color:#111;'> 137B </span>","children":null,"spread":false},{"title":"IOCP_Server.ncb <span style='color:#111;'> 171.00KB </span>","children":null,"spread":false},{"title":"IOCP_Server.suo <span style='color:#111;'> 13.50KB </span>","children":null,"spread":false},{"title":"IOCP_Server.vssscc <span style='color:#111;'> 256B </span>","children":null,"spread":false},{"title":"mssccprj.scc <span style='color:#111;'> 162B </span>","children":null,"spread":false}],"spread":true}],"spread":true}]

评论信息

  • ccReader :
    资源好用,多谢分享!
    2016-08-03
  • fbgv060 :
    随便改了一下就用到项目里了,十分方便
    2016-07-27
  • 唔佲 :
    谢谢共享,值得学习!
    2016-07-15
  • fengyangfei :
    正在研究这方面的东西,感谢楼主~!
    2016-05-06
  • xiaoyinghui :
    很好, 谢谢分享!
    2015-07-29

免责申明

【只为小站】的资源来自网友分享,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,【只为小站】 无法对用户传输的作品、信息、内容的权属或合法性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论 【只为小站】 经营者是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。
本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二条之规定,若资源存在侵权或相关问题请联系本站客服人员,zhiweidada#qq.com,请把#换成@,本站将给予最大的支持与配合,做到及时反馈和处理。关于更多版权及免责申明参见 版权及免责申明