Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xds: eds reuse priority names for the same existing locality #9287

Merged
merged 3 commits into from
Jun 24, 2022

Conversation

YifeiZhuang
Copy link
Contributor

@YifeiZhuang YifeiZhuang commented Jun 18, 2022

@YifeiZhuang YifeiZhuang requested a review from ejona86 June 18, 2022 00:07
}
}
if ("".equals(foundName)) {
foundName = String.format("%s[priority%d]", name, priorityNameGenId++);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we only have to update tests in ClusterResolverLoadBalancerTest, let's change "priority" to "child" like we had briefly discussed. There aren't that many occurrences in ClusterResolverLoadBalancerTest to keep around this confusion.

@@ -342,6 +345,8 @@ void shutdown() {
private final class EdsClusterState extends ClusterState implements EdsResourceWatcher {
@Nullable
private final String edsServiceName;
private Map<Locality, String> localityPriorityNames = new HashMap<>();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Collections.emptyMap() would make it a bit more obvious the reference is modified instead of the map itself.

@YifeiZhuang YifeiZhuang merged commit dc8954d into grpc:master Jun 24, 2022
@YifeiZhuang YifeiZhuang deleted the reuse-priority-name branch June 24, 2022 23:16
larry-safran pushed a commit to larry-safran/grpc-java that referenced this pull request Jun 28, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants