Skip to content

Commit

Permalink
Ignore clusterstate.json. Fixes django-haystack#224.
Browse files Browse the repository at this point in the history
  • Loading branch information
rokclimb15 committed Sep 15, 2023
1 parent bacad23 commit e23e4ce
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions pysolr.py
Original file line number Diff line number Diff line change
Expand Up @@ -1530,7 +1530,6 @@ class ZooKeeper(object):
# Constants used by the REST API:
LIVE_NODES_ZKNODE = "/live_nodes"
ALIASES = "/aliases.json"
CLUSTER_STATE = "/clusterstate.json"
COLLECTION_STATUS = "/collections"
COLLECTION_STATE = "/collections/%s/state.json"
SHARDS = "shards"
Expand Down Expand Up @@ -1574,14 +1573,6 @@ def connectionListener(state):

self.zk.add_listener(connectionListener)

@self.zk.DataWatch(ZooKeeper.CLUSTER_STATE)
def watchClusterState(data, *args, **kwargs):
if not data:
LOG.warning("No cluster state available: no collections defined?")
else:
self.collections = json.loads(data.decode("utf-8"))
LOG.info("Updated collections: %s", self.collections)

@self.zk.ChildrenWatch(ZooKeeper.LIVE_NODES_ZKNODE)
def watchLiveNodes(children):
self.liveNodes = children
Expand Down

0 comments on commit e23e4ce

Please sign in to comment.