Rename PooledThread.start -> mainloop.
This commit is contained in:
parent
f1aea14646
commit
dcd4d20b07
1 changed files with 2 additions and 2 deletions
|
@ -67,7 +67,7 @@ class PooledThread:
|
||||||
'''
|
'''
|
||||||
def __init__(self, pool):
|
def __init__(self, pool):
|
||||||
self.pool = pool
|
self.pool = pool
|
||||||
self.thread = threading.Thread(target=self.start, daemon=True)
|
self.thread = threading.Thread(target=self.mainloop, daemon=True)
|
||||||
self.thread.start()
|
self.thread.start()
|
||||||
|
|
||||||
def __repr__(self):
|
def __repr__(self):
|
||||||
|
@ -103,7 +103,7 @@ class PooledThread:
|
||||||
log.debug('%s is joining.', self)
|
log.debug('%s is joining.', self)
|
||||||
self.thread.join()
|
self.thread.join()
|
||||||
|
|
||||||
def start(self):
|
def mainloop(self):
|
||||||
while True:
|
while True:
|
||||||
# Let's wait for jobs_available first and unpaused second.
|
# Let's wait for jobs_available first and unpaused second.
|
||||||
# If the time between the two waits is very long, the worst thing
|
# If the time between the two waits is very long, the worst thing
|
||||||
|
|
Loading…
Reference in a new issue