Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Catalog · How the catalog works

Random project

diocp-v5

delphi iocp, http, websocket, ntrip

View on GitHub

Anyone may press Interesting, signed in or not. It helps others find this project.

Member rating

No ratings yet.

Sign in to rate this project.

README

diocp5

快速开始

pascal
???????????????:
 git??????(??????????????????)
  1.https://github.com/ymofen/diocp-v5
  2.https://gitee.com/ymofen/diocp-v5
?????????zip??????
  https://codeload.github.com/ymofen/diocp-v5/zip/master
pascal
FAQ??????:
  http://note.youdao.com/noteshare?id=2b40e5d99f39a57512d739f0a5a8a3ee
pascal
??????Delphi????????????
  DIOCP5_HOME=E:\workspace\diocp-v5
pascal
????????????
  $(DIOCP5_HOME)\Source

FAQ

Q:同时启动两个Diocp服务, 为什么一个处理逻辑慢, 会影响到另外一个服务也变慢

pascal
A: Diocp???????????????????????????IocpEngine, ??????Diocp????????????????????????Iocp???????????????????????????????????????????????????
  1>. ??????DiocpTcpServer??????????????????IocpEngine. 
      ?????????FTcpServer.BindDiocpEngine(TIocpEngine.Create, true);
  2>. ????????????IocpEngine????????????, IocpEngine???????????????????????????:cpu??????* 2-1
  3>. ??????????????????????????????????????????????????????????????????????????????????????????
  4>. Http????????????????????????diocpTask????????????????????????diocpTask???????????????????????????: cpu * 2 -1???
      ????????????diocp_task.pas, ????????????app??????????????? iocpTaskManager.setWorkerCount(50);
      ?????????APP?????????????????????QDAC_QWorker, ????????????qworkers?????????

注意的一些事情

HTTP协议

关于ResponseStream, ResponesAFile

如果使用这两个过程响应Http, Diocp会分块发送数据,直达发送所有的数据发送完成,然后进行判断是否需要关闭连接。所以您不需要进行其他的响应(SendResponse), 也不需要执行ResponseEnd,也不能提前把Stream进行释放,Diocp的Http会接管处理他。

目录说明:

pascal
samples                        ???????????????DEMO
source                         ????????????????????????
pascal
?????????????????????DEMO?????????diocp???????????????
  samples\ECHO
  samples\simple
  samples\StringDEMO

关于文档帮助

pascal
DIOCP QQ ???: 638127021  
DIOCP????????????: www.diocp.org

关于捐助:

pascal
DIOCP5??????BSD???????????????????????????????????????????????????????????????????????????????????????
???????????????DIOCP5????????????????????????????????????DIOCP5????????????,?????????????????????????????????????????????
pascal
?????????????????????
?????????ymofen@diocp.org
??????: ?????????