[ 
https://issues.apache.org/jira/browse/HDFS-5208?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13771529#comment-13771529
 ] 

Junping Du commented on HDFS-5208:
----------------------------------

Thanks for comments, Colin!
bq. Unfortunately, DatanodeID#getHostName doesn't actually return the hostname. 
It returns DatanodeID#hostName, which is either the registration name (if it 
was specified) or the hostname (if it was not.)
So, we are saying the same thing - "DatanodeID is created in DN heartbeat to NN 
for registration and its hostName comes from conf of "dfs.datanode.hostname" 
which can be any style but DNS name if this config is not setting." - Isn't it? 
:)
bq. I think this feature is mainly used in unit tests to fake up having 
different hostnames-- something we could probably do this in a much simpler 
way. We've discussed creating a JIRA to remove it before-- maybe it's time.
I agree. Will file separated Jira and work on it later. So we may just do 
simply two things below:
1. remove config of "dfs.datanode.hostname" and all usage place.
2. make sure DatanodeID#hostname is its hostname (DNS name).
Anything else to address?

                
> Only clear network location cache on specific nodes if invalid 
> NetworkTopology happens
> --------------------------------------------------------------------------------------
>
>                 Key: HDFS-5208
>                 URL: https://issues.apache.org/jira/browse/HDFS-5208
>             Project: Hadoop HDFS
>          Issue Type: Improvement
>            Reporter: Junping Du
>            Assignee: Junping Du
>         Attachments: HDFS-5208-v1.patch
>
>
> After HDFS-4521, once a DN is registered with invalid networktopology, all 
> cached rack info in DNSToSwitchMapping will be cleared. We should only clear 
> cache on specific nodes.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to