mirror of https://github.com/grpc/grpc-node.git
Fix detection of refused streams
This commit is contained in:
parent
a120aa06b3
commit
95516b66a0
|
@ -159,7 +159,7 @@ export class LoadBalancingCall implements Call {
|
|||
},
|
||||
onReceiveStatus: status => {
|
||||
this.trace('Received status');
|
||||
if (status.code === http2.constants.NGHTTP2_REFUSED_STREAM) {
|
||||
if (status.rstCode === http2.constants.NGHTTP2_REFUSED_STREAM) {
|
||||
this.outputStatus(status, 'REFUSED');
|
||||
} else {
|
||||
this.outputStatus(status, 'PROCESSED');
|
||||
|
|
|
@ -385,7 +385,7 @@ export class RetryingCall implements Call {
|
|||
if (this.underlyingCalls[callIndex].state === 'COMPLETED') {
|
||||
return;
|
||||
}
|
||||
this.trace('state=' + this.state + ' handling status from child [' + this.underlyingCalls[callIndex].call.getCallNumber() + '] in state ' + this.underlyingCalls[callIndex].state);
|
||||
this.trace('state=' + this.state + ' handling status with progress ' + status.progress + ' from child [' + this.underlyingCalls[callIndex].call.getCallNumber() + '] in state ' + this.underlyingCalls[callIndex].state);
|
||||
this.underlyingCalls[callIndex].state = 'COMPLETED';
|
||||
if (status.code === Status.OK) {
|
||||
this.retryThrottler?.addCallSucceeded();
|
||||
|
|
Loading…
Reference in New Issue