Commit f7bb43f3 authored by U. Artie Eoff's avatar U. Artie Eoff Committed by Chad Versace
Browse files

Add ConcurrentTestPool singleton.

The ConcurrentTestPool singleton will simplify the threading model
and remove the need to manage multiple ThreadPools.  Only one
threadpool is currently needed at this time and is meant to execute
cpu-only tests in separate threads.
Reviewed-by: default avatarChad Versace <>
parent e8c39dc7
......@@ -41,6 +41,22 @@ def synchronized_self(function):
synchronized_self.locks = WeakKeyDictionary() # track the locks for each instance
class ConcurrentTestPool(Singleton):
def init(self):
self.pool = ThreadPool(2)
def put(self, callable_, args = None, kwds = None):
callable_, args = args, kwds = kwds
def join(self):
class ThreadPools(Singleton):
def init(self):
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment