Removed Cluster.is_idle

It wasn't used and it could be confused with the cluster stat IDLE
This commit is contained in:
Ilan Steemers
2015-07-06 11:13:54 +02:00
parent c8095cb699
commit d06aa40a38
2 changed files with 0 additions and 6 deletions
-5
View File
@@ -49,7 +49,6 @@ class Cluster(object):
self.sentinel = None
self.stop_event = None
self.start_event = None
self.stopped_event = None
self.pid = current_process().pid
self.host = socket.gethostname()
self.list_key = list_key
@@ -111,10 +110,6 @@ class Cluster(object):
def has_stopped(self):
return self.start_event is None and self.stop_event is None and self.sentinel
@property
def is_idle(self):
return self.sentinel is None
class Sentinel(object):
def __init__(self, stop_event, start_event, list_key=Conf.Q_LIST, timeout=Conf.TIMEOUT, start=True):
-1
View File
@@ -39,7 +39,6 @@ def test_cluster_initial(r):
r.delete(list_key)
c = Cluster(list_key=list_key)
assert c.sentinel is None
assert c.is_idle
assert c.start() > 0
assert c.sentinel.is_alive() is True
assert c.is_running