Name task adding lock

This commit is contained in:
shortcutme 2019-12-31 12:50:39 +01:00
parent ba218974c4
commit 5987274edf
No known key found for this signature in database
GPG Key ID: 5B63BAE6CB9613AE
1 changed files with 1 additions and 1 deletions

View File

@ -21,7 +21,7 @@ class WorkerManager(object):
self.workers = {} # Key: ip:port, Value: Worker.Worker
self.tasks = WorkerTaskManager()
self.next_task_id = 1
self.lock_add_task = DebugLock()
self.lock_add_task = DebugLock(name="Lock AddTask:%s" % self.site.address_short)
# {"id": 1, "evt": evt, "workers_num": 0, "site": self.site, "inner_path": inner_path, "done": False, "optional_hash_id": None,
# "time_started": None, "time_added": time.time(), "peers": peers, "priority": 0, "failed": peer_ids, "lock": None or gevent.lock.RLock}
self.started_task_num = 0 # Last added task num