hadoop-common-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Devaraj Das (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HADOOP-395) infoPort field should be a DatanodeID member
Date Fri, 28 Jul 2006 12:01:15 GMT
    [ http://issues.apache.org/jira/browse/HADOOP-395?page=comments#action_12424076 ] 
Devaraj Das commented on HADOOP-395:

Noticed now that Konstantin's patch for Hadoop-396 will make this patch go stale. So I will
submit another patch after Konstantin's patch is committed. Please don't commit this patch
for now.

> infoPort field should be a DatanodeID member
> --------------------------------------------
>                 Key: HADOOP-395
>                 URL: http://issues.apache.org/jira/browse/HADOOP-395
>             Project: Hadoop
>          Issue Type: Improvement
>    Affects Versions: 0.4.0
>            Reporter: Konstantin Shvachko
>         Assigned To: Devaraj Das
>             Fix For: 0.5.0
>         Attachments: refactor_infoport.patch
> I have a couple of comments on HADOOP-375. Sorry missed that discussion when the patch
was under construction.
> 1) As it is done now infoPort is a member of two classes DatanodeInfo and DatanodeRegistration,
which in fact have a
> common base DatanodeID. It seems more logical to place infoPort into DatanodeID. This
will let us handle the port
> assignments inside the constructors rather than outside, and will prevent from unsafe
"dynamic casts" like the one
> found in FSNamesystem.gotHeartbeat( DatanodeID nodeID, ... )
>             nodeinfo.infoPort = ((DatanodeRegistration)nodeID).infoPort;
> 2) Also, should we make infoPort short rather than integer?
> Since it is a part of a heartbeat message we might want keeping it small.
> 3) Member getters should start with get<MemberName>
> - public int infoPort() { return infoPort; }
> + public int getInfoPort() { return infoPort; }

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message