xds: apply initial backoff even if we got a response on the previous call (#29251)

pull/29256/head
Mark D. Roth 3 years ago committed by GitHub
parent fbed598f01
commit efba405e45
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 12
      src/core/ext/xds/xds_client.cc

@ -683,18 +683,12 @@ void XdsClient::ChannelState::RetryableCall<T>::Orphan() {
template <typename T>
void XdsClient::ChannelState::RetryableCall<T>::OnCallFinishedLocked() {
const bool seen_response = calld_->seen_response();
// If we saw a response on the current stream, reset backoff.
if (calld_->seen_response()) backoff_.Reset();
calld_.reset();
if (seen_response) {
// If we lost connection to the xds server, reset backoff and restart the
// call immediately.
backoff_.Reset();
StartNewCallLocked();
} else {
// If we failed to connect to the xds server, retry later.
// Start retry timer.
StartRetryTimerLocked();
}
}
template <typename T>
void XdsClient::ChannelState::RetryableCall<T>::StartNewCallLocked() {

Loading…
Cancel
Save