[
https://issues.apache.org/jira/browse/HDFS-13348?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16425607#comment-16425607
]
Nanda kumar commented on HDFS-13348:
------------------------------------
In {{RegisteredCommand}} can we not have hostname and ipAddress as mandatory
fields, as they are not required fields in {{SCMRegisteredCmdResponseProto}}.
We can have two constructors
{code:java}
public RegisteredCommand(final ErrorCode error, final String datanodeUUID,
final String clusterID) {
this(error, datanodeUUID, clusterID, null, null);
}
public RegisteredCommand(final ErrorCode error, final String datanodeUUID,
final String clusterID, final String hostname, final String ipAddress) {
....
}
{code}
Having empty string for hostname and ipAddress will become somewhat difficult
to figure out if it's actually set by someone or not.
> Ozone: Update IP and hostname in Datanode from SCM's response to the register
> call
> ----------------------------------------------------------------------------------
>
> Key: HDFS-13348
> URL: https://issues.apache.org/jira/browse/HDFS-13348
> Project: Hadoop HDFS
> Issue Type: Sub-task
> Components: ozone
> Reporter: Nanda kumar
> Assignee: Shashikant Banerjee
> Priority: Major
> Attachments: HDFS-13348-HDFS-7240.000.patch,
> HDFS-13348-HDFS-7240.001.patch
>
>
> Whenever a Datanode registers with SCM, the SCM resolves the IP address and
> hostname of the Datanode form the RPC call. This IP address and hostname
> should be sent back to Datanode in the response to register call and the
> Datanode has to update the values from the response to its
> {{DatanodeDetails}}.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]