DataNode.getDNRegistrationByMachineName can probably be removed or simplified
-----------------------------------------------------------------------------

                 Key: HDFS-2609
                 URL: https://issues.apache.org/jira/browse/HDFS-2609
             Project: Hadoop HDFS
          Issue Type: Improvement
          Components: data-node
    Affects Versions: 0.23.0
            Reporter: Todd Lipcon


I noticed this while working on HDFS-1971: The 
{{getDNRegistrationByMachineName}} iterates over block pools to return a given 
block pool's registration object based on its {{machineName}} field. But, the 
machine name for every BPOfferService is identical - they're always constructed 
by just calling {{DataNode.getName}}. All of the call sites for this function 
are from tests, as well. So, maybe it's not necessary, or at least it might be 
able to be simplified or moved to a test method.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to