|
|
|
@ -444,9 +444,11 @@ class Pool(object):
|
|
|
|
self.add(service)
|
|
|
|
self.add(service)
|
|
|
|
self._threads = []
|
|
|
|
self._threads = []
|
|
|
|
for x in range(size):
|
|
|
|
for x in range(size):
|
|
|
|
|
|
|
|
name = 'mitogen.service.Pool.%x.worker-%d' % (id(self), x,)
|
|
|
|
thread = threading.Thread(
|
|
|
|
thread = threading.Thread(
|
|
|
|
name='mitogen.service.Pool.%x.worker-%d' % (id(self), x,),
|
|
|
|
name=name,
|
|
|
|
target=self._worker_main,
|
|
|
|
target=mitogen.core._profile_hook,
|
|
|
|
|
|
|
|
args=(name, self._worker_main),
|
|
|
|
)
|
|
|
|
)
|
|
|
|
thread.start()
|
|
|
|
thread.start()
|
|
|
|
self._threads.append(thread)
|
|
|
|
self._threads.append(thread)
|
|
|
|
|