相关文章推荐
瘦瘦的企鹅  ·  matlab统一色标 - CSDN文库·  4 月前    · 
英勇无比的野马  ·  javascript - ...·  1 年前    · 
正直的松球  ·  antd-table ...·  1 年前    · 
Collectives™ on Stack Overflow

Find centralized, trusted content and collaborate around the technologies you use most.

Learn more about Collectives

Teams

Q&A for work

Connect and share knowledge within a single location that is structured and easy to search.

Learn more about Teams

If I assign an TIdSchedulerOfThreadPool to my IdTCPServer, will I still be limited to the number of simultaneous connections?

My IdTCPServer properties are :

 ListenQueue : 30
   MaxConnections : 0
   ReuseSocket rsTrue
   Scheduler :MyIdSchedulerOfThreadPool
   TerminateWaitTime : 5000

MyIdSchedulerOfThreadPool's properties :

Scheduler: MyIdSchedulerOfThreadPool
MaxThreads = 0
PoolSize = 0
ThreqdPriority = tpNormal

No coding; I just assign the MyIdSchedulerOfThreadPool to Scheduler.

Welcome to Stack Overflow. You've asked two entirely unrelated questions. Please pick one to ask here in this post. Then edit the post to remove the other question, and post it separately. – Rob Kennedy Sep 5, 2013 at 19:54

The TIdTCPServer.MaxConnections property controls how many simultaneous clients are allowed to be connected at a time.

The TIdSchedulerOfThread.MaxThreads property controls how many simultaneous threads are allowed to be running at a time (idle or otherwise).

The TIdSchedulerOfThreadPool.PoolSize property controls how many simultaneous idle threads are allowed to be in the pool at a time.

So when you have a TIdSchedulerOfThread... assigned, the max number of simultaneous connections is really the smaller value between the MaxConnections and MaxThreads properties, since each client connection requires a thread to manage it.

Thanks for contributing an answer to Stack Overflow!

  • Please be sure to answer the question. Provide details and share your research!

But avoid

  • Asking for help, clarification, or responding to other answers.
  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.