Skip to content

feat: add domain re-resolution support for Go client#2335

Open
nanorth wants to merge 3 commits intoapache:masterfrom
nanorth:feat_go_client_domain
Open

feat: add domain re-resolution support for Go client#2335
nanorth wants to merge 3 commits intoapache:masterfrom
nanorth:feat_go_client_domain

Conversation

@nanorth
Copy link
Contributor

@nanorth nanorth commented Dec 11, 2025

What problem does this PR solve?

Currently, the Go client resolves the domain names of meta nodes only once during initialization and stores the resulting IP addresses. After that, it does not re-resolve the domain names, even if the underlying IP addresses change. This can lead to connection issues, especially in environments where domain resolution may change during runtime — such as when using a meta proxy backed by LVS.

This PR adds domain resolution support to the Go client, allowing it to re-resolve the domain name when all meta nodes fail to respond.

Tests
  • Unit tests added to simulate meta node failures and verify re-resolution behavior. These tests verify that the client correctly triggers a domain re-resolution and is able to reconnect using the newly resolved IP addresses.

zhoutongxi added 2 commits December 12, 2025 09:43
@nanorth nanorth changed the title feat: add domain resolution support for Go client feat: add domain re-resolution support for Go client Dec 12, 2025
@nanorth nanorth marked this pull request as ready for review December 26, 2025 06:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant