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.
–
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.