Merge "sharding: better handle get_shard_ranges failures"

This commit is contained in:
Zuul 2019-08-02 13:17:51 +00:00 committed by Gerrit Code Review
commit a563f4f5a6

View File

@ -138,7 +138,7 @@ class ContainerReplicator(db_replicator.Replicator):
def _fetch_and_merge_shard_ranges(self, http, broker):
with Timeout(self.node_timeout):
response = http.replicate('get_shard_ranges')
if is_success(response.status):
if response and is_success(response.status):
broker.merge_shard_ranges(json.loads(
response.data.decode('ascii')))