阅读背景:

节俭中的大量同时连接

来源:互联网 

I'm trying to write a simple server with Thrift. At the beginning it looked promising, but I've stumbled into a problem with a number of clients connected at the same time. I'm using TThreadPoolServer, which allows 4 client to connect and then blocks other clients until I kill one from the connected. What can I do to allow more (possibly several hundreds) clients to be connected at the same time, without increasing the number of threads. I assumed that the worker threads allow to perform one client request at a time, but it looks like one thread handles one connection until it is closed. I'd like to avoid a situation when my clients has to reopen a socket to perform an action.I'm trying to write a simple server with Thrift




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: