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

resolvePeers() overrides peer lookup behaviour in memberlist library #219

Closed
mattbostock opened this issue Feb 27, 2018 · 2 comments
Closed

Comments

@mattbostock
Copy link
Contributor

The resolvePeers() function in the cluster package tries to resolve the IP addresses for the cluster peers:
https://github.com/improbable-eng/thanos/blob/19ff509a4f658887f90ab543c79cc821762f64cd/pkg/cluster/cluster.go#L423-L476

It does this using the Go DNS resolver.

The memberlist library does the same thing, but uses TCP first in a bid to retrieve as many peers as possible:
https://github.com/hashicorp/memberlist/blob/ce8abaa0c60c2d6bee7219f5ddf500e0a1457b28/memberlist.go#L303-L306

Go's resolver may try TCP if the UDP query results in a truncated response, so maybe this is not an issue. But it seems like Thanos is doing more than it needs to - there's a lot of overlap between the code in these two places.

Should Thanos delegate DNS resolution for peers to the memberlist library, and is there a compelling reason for it to do its own resolution as it is currently?

@yeya24
Copy link
Contributor

yeya24 commented Aug 3, 2019

Can we close this issue now? Since cluster has been removed.

@povilasv
Copy link
Member

povilasv commented Aug 5, 2019

👍 closing the issue as gossip is removed.

@povilasv povilasv closed this as completed Aug 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants