diff options
author | 2017-05-25 15:13:27 -0700 | |
---|---|---|
committer | 2017-05-25 15:13:27 -0700 | |
commit | c18b9069cd37083f34e8e3c1601eb20944914ee5 (patch) | |
tree | 43943d620ecb7a984694766a273823fd34eebad5 /src/python/grpcio | |
parent | 0a94f3c8ab55dfd12c14058d57f33121c8d6c411 (diff) | |
parent | 3410c8d7dc86fe7778d6795340d9792acb1b912b (diff) |
Merge remote-tracking branch 'upstream/v1.3.x' into master_1.3.x_upmerge
Diffstat (limited to 'src/python/grpcio')
-rw-r--r-- | src/python/grpcio/grpc/_channel.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/python/grpcio/grpc/_channel.py b/src/python/grpcio/grpc/_channel.py index 4316449ac6..012ed8ec81 100644 --- a/src/python/grpcio/grpc/_channel.py +++ b/src/python/grpcio/grpc/_channel.py @@ -786,7 +786,7 @@ def _channel_managed_call_management(state): class _ChannelConnectivityState(object): def __init__(self, channel): - self.lock = threading.Lock() + self.lock = threading.RLock() self.channel = channel self.polling = False self.connectivity = None @@ -926,6 +926,11 @@ class Channel(grpc.Channel): self._call_state = _ChannelCallState(self._channel) self._connectivity_state = _ChannelConnectivityState(self._channel) + # TODO(https://github.com/grpc/grpc/issues/9884) + # Temporary work around UNAVAILABLE issues + # Remove this once c-core has retry support + _subscribe(self._connectivity_state, lambda *args: None, None) + def subscribe(self, callback, try_to_connect=None): _subscribe(self._connectivity_state, callback, try_to_connect) |