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

gossip: don't resolve addresses under lock #95349

Closed
erikgrinaker opened this issue Jan 17, 2023 · 2 comments · Fixed by #95426
Closed

gossip: don't resolve addresses under lock #95349

erikgrinaker opened this issue Jan 17, 2023 · 2 comments · Fixed by #95426
Assignees
Labels
A-kv-gossip C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.

Comments

@erikgrinaker
Copy link
Contributor

erikgrinaker commented Jan 17, 2023

Similarly to #70038, in 21.2 we can end up attempting to resolve a DNS address while holding the gossip mutex:

if _, err := reply.AlternateAddr.Resolve(); err != nil {
return errors.Errorf("unable to resolve alternate address %s for n%d: %s",
reply.AlternateAddr, reply.AlternateNodeID, err)
}

We don't even use the result of this lookup. We should remove it.

Jira issue: CRDB-23469

@erikgrinaker erikgrinaker added C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior. A-kv-gossip T-kv-replication labels Jan 17, 2023
@blathers-crl
Copy link

blathers-crl bot commented Jan 17, 2023

cc @cockroachdb/replication

@erikgrinaker erikgrinaker self-assigned this Jan 18, 2023
@erikgrinaker
Copy link
Contributor Author

Resolved by #95426.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-kv-gossip C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant