Cosmin Prund wrote: > The server should return any available text for the given conversation > or an NOP if no text is available. But here's a trick: If there's no > text available for the connection I would like to delay returning an > NOP until there IS some text available, or until a 10 seconds delay > elapses. This would stop the client from going into a bandwidth- > consuming busy-loop.
You realy do not need multiple threads to achieve that, send the response when text is available or close the connection after 10 seconds. Multi-threading should be used only when the client needs to carry out lengthy jobs like executing a SQL query or calculating a MD5 checksum on a big, uploaded file. --- Arno Garrels [TeamICS] http://www.overbyte.be/eng/overbyte/teamics.html > > Unfortunately THttpServer doesn't include a "MultiThreaded" checkbox > like TSocketServer does, and I'm not sure what I should do to Sleep() > without actually freezing the server in the process! I might try > subclassing THttpServer and setting FWSocketServer.MultiThreaded = > True in CreateSocket but I know too little about the internals of > THttpServer and ICS in general to understand the consequences of > doing this. > > Any help on the matter is welcomed, thanks. > > -- > Cosmin Prund -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be