diff options
Diffstat (limited to 'cpp/src/Ice/Instance.cpp')
-rw-r--r-- | cpp/src/Ice/Instance.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/cpp/src/Ice/Instance.cpp b/cpp/src/Ice/Instance.cpp index 80de465fc35..1d91358294d 100644 --- a/cpp/src/Ice/Instance.cpp +++ b/cpp/src/Ice/Instance.cpp @@ -193,7 +193,8 @@ IceInternal::Instance::clientThreadPool() { if(!_clientThreadPool) // Lazy initialization. { - _clientThreadPool = new ThreadPool(this, false); + int threadNum = _properties->getPropertyAsIntWithDefault("Ice.ThreadPool.Client.Size", 1); + _clientThreadPool = new ThreadPool(this, threadNum, 0); } } @@ -209,7 +210,9 @@ IceInternal::Instance::serverThreadPool() { if(!_serverThreadPool) // Lazy initialization. { - _serverThreadPool = new ThreadPool(this, true); + int threadNum = _properties->getPropertyAsIntWithDefault("Ice.ThreadPool.Server.Size", 10); + int timeout = _properties->getPropertyAsInt("Ice.ServerIdleTime"); + _serverThreadPool = new ThreadPool(this, threadNum, timeout); } } |