Skip to content

Commit

Permalink
Merge pull request #2576 from murgatroid99/grpc-js_picker_propagation…
Browse files Browse the repository at this point in the history
…_fix

grpc-js: Delegate to child picker in ResolvingLoadBalancer#updateResolution
  • Loading branch information
murgatroid99 authored Sep 21, 2023
2 parents ddb8de2 + 5be024f commit 47c54ec
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion packages/grpc-js/src/resolving-load-balancer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,11 @@ export class ResolvingLoadBalancer implements LoadBalancer {
private updateResolution() {
this.innerResolver.updateResolution();
if (this.currentState === ConnectivityState.IDLE) {
this.updateState(ConnectivityState.CONNECTING, new QueuePicker(this));
/* this.latestChildPicker is initialized as new QueuePicker(this), which
* is an appropriate value here if the child LB policy is unset.
* Otherwise, we want to delegate to the child here, in case that
* triggers something. */
this.updateState(ConnectivityState.CONNECTING, this.latestChildPicker);
}
this.backoffTimeout.runOnce();
}
Expand Down

0 comments on commit 47c54ec

Please sign in to comment.