mirror of
https://github.com/opensim/opensim.git
synced 2026-08-10 03:06:05 +08:00
Assign the SmartThreadPool name in the constructor
This is required because some threads are created in the constructor, so assigning the name afterwards would be too late.
This commit is contained in:
committed by
Justin Clark-Casey (justincc)
parent
3eee991935
commit
b77da5039e
@@ -1658,8 +1658,13 @@ namespace OpenSim.Framework
|
||||
if (m_ThreadPool != null)
|
||||
throw new InvalidOperationException("SmartThreadPool is already initialized");
|
||||
|
||||
m_ThreadPool = new SmartThreadPool(2000, maxThreads, 2);
|
||||
m_ThreadPool.Name = "Util";
|
||||
STPStartInfo startInfo = new STPStartInfo();
|
||||
startInfo.ThreadPoolName = "Util";
|
||||
startInfo.IdleTimeout = 2000;
|
||||
startInfo.MaxWorkerThreads = maxThreads;
|
||||
startInfo.MinWorkerThreads = 2;
|
||||
|
||||
m_ThreadPool = new SmartThreadPool(startInfo);
|
||||
}
|
||||
|
||||
public static int FireAndForgetCount()
|
||||
|
||||
Reference in New Issue
Block a user