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

Refresh name resolution if all addresses failed to connect. #1591

Merged
merged 1 commit into from
Mar 24, 2016

Conversation

zhangkun83
Copy link
Contributor

Resolves #1463

@@ -94,7 +117,7 @@ public void run() {
try {
inetAddrs = InetAddress.getAllByName(host);
} catch (Exception e) {
listener.onError(Status.UNAVAILABLE.withCause(e));
savedListener.onError(Status.UNAVAILABLE.withCause(e));
return;
Copy link
Member

Choose a reason for hiding this comment

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

resolving = false isn't done in this code path. You may consider a try-finally (although it is unfortunate it would increase the indentation).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Nice catch. Done.

@ejona86
Copy link
Member

ejona86 commented Mar 24, 2016

@zhangkun83, one important comment/bug, but otherwise LGTM

@ejona86
Copy link
Member

ejona86 commented Mar 24, 2016

@zhangkun83 LGTM

@zhangkun83 zhangkun83 merged commit 3be48b4 into grpc:master Mar 24, 2016
@zhangkun83 zhangkun83 deleted the refresh_dns branch March 24, 2016 21:41
@lock lock bot locked as resolved and limited conversation to collaborators Jan 21, 2019
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