Skip to content

HDDS-13124. Respect config hdds.datanode.use.datanode.hostname when reading from datanode #8518

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

Merged
merged 1 commit into from
May 28, 2025

Conversation

KochankovID
Copy link
Contributor

Enable the use of host name datanodes when working with ozone for selecting

Please describe your PR in detail:
This PR introduces an optional configuration to use DataNode hostnames instead of IP addresses for gRPC connections in Ozone.

Key changes:

  • Modified XceiverClientGrpc.java to check configuration HDDS_DATANODE_USE_DN_HOSTNAME and use either hostname or IP address when creating gRPC channels

  • Updated debug logging to show hostname information

The change provides more flexibility in environments where hostname-based identification is preferred over IP addresses. This can be particularly useful in dynamic environments where IP addresses might change but hostnames remain consistent.

https://issues.apache.org/jira/browse/HDDS-13124

How was this patch tested?

unit tests, manual tests, workflow run on the fork git repo

Copy link
Contributor

@adoroszlai adoroszlai left a comment

Choose a reason for hiding this comment

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

Thanks @KochankovID for the patch, LGTM.

@adoroszlai adoroszlai changed the title HDDS-13124. Enable the use of host name datanodes when working with ozone for selecting HDDS-13124. Respect config hdds.datanode.use.datanode.hostname when reading from datanode May 28, 2025
@adoroszlai adoroszlai merged commit 7027ab7 into apache:master May 28, 2025
43 checks passed
@adoroszlai
Copy link
Contributor

Thanks @KochankovID for the patch, @peterxcli for the review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants