Skip to content

Commit

Permalink
Virtual targets and duplicate entries in channels map
Browse files Browse the repository at this point in the history
  • Loading branch information
panic08 committed Dec 2, 2024
1 parent 5c0ca70 commit 16ca26b
Show file tree
Hide file tree
Showing 7 changed files with 514 additions and 505 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,10 @@ public void setCredentialsProvider(ChannelCredentialsProvider credentials) {

@Override
public ManagedChannelBuilder<?> createChannel(String authority) {
String target = this.targets.getTarget(authority);
if (this.channels.containsKey(target)) {
return this.builders.get(authority);
}
return this.createChannel(authority, List.of(), false);
}

Expand Down
Loading

0 comments on commit 16ca26b

Please sign in to comment.