04-14-2022, 12:22 AM
I'm using TIdHTTPServer and TIdTCPServer components in a Delphi game server app (actually a Windows service app). Does Indy create additional threads beyond what it gives to each individual connection? If so, is there any way for my app to fetch their ThreadID numbers during runtime? I ask because I'm presenting a list of active threads and what they are doing. I can of course track the ones I created myself and use the Indy OnConnect/OnDisconnect events to add/remove the connection threads to/from my list. But my list is usually about 16 short of the total that Windows says belong to my app. I'm sure most of those are Windows kernal threads or Delphi worker threads present in all apps but I'd like to narrow down the "unknown" count to as small a number as possible.