From: Neil C. <nc...@kl...> - 2002-03-20 05:23:16
|
Hi all, I have an application I'm designing that may or may not be suitable for use with ST. The application should be able to handle a fair number (128-1024) of concurrent TCP connections. Of these, half will be inbound and half will be outbound (there is always a 1:1 relationship between inbound and outbound connections). It won't need to do a lot of processing on the data that comes in; most of the time it will just be copying data from the inbound socket to the outbound socket, and vice versa. It will need very rapid access (i.e. as scaleable & fast as possible) to a single shared data structure (this is a cache: the whole point of this is to get a lot of cache hits, so I'd like all the threads to be able to access a single cache). There is a single unique value for each unique key, so the cache could be implemented as a hash table. This application will also need to be able to scale with the number of CPUs in the machine: simply using a single CPU is not optimal. Is this a good candidate for using ST? AFAIK, it is considered good practice with ST to create several processes to allow for system scalability. This would work well, but wouldn't IPC be a significant performance hit? I'll be doing several operations on the hash table for each connection; furthermore, an operation might need to insert or retrieve a relatively large amount of data from the table (10 to 100 KB). I would be grateful for any advice on how to design my application to work with ST -- or, if ST isn't an appropriate choice, the best I/O design to use. Thanks in advance, Neil -- Neil Conway <nei...@ro...> PGP Key ID: DB3C29FC |