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

Lei (Eddy) Xu commented on HDFS-9005:
-------------------------------------

Hi, [~mingma] Thanks a lot for uploading this patch.

I have a few questions regarding the JSON file and the code

* What is the expected format for the JSON file? E.g., it seems that each DN 
has a separate JSON object? what is the pros and cons comparing putting them 
into an JSON array? 
* As mentioned previously, it is going to put include/exclude files into "all" 
file. Do we use different section (keys) to determine the included / excluded 
DNs or using the {{AdminState}}, it'd be nice to clarify that.
* In {{HostsFileWriter#includeHosts/excludeHost}}, it seems that each function 
overwrite the whole conf file? Is it a expected behavior?  

A few minor issues:
* There are a few comments that are not jdoc format. 
* Could you add more comments to {{HostConfigManager}}, 
{{DatanodeAdminProperties}}
* It seems only changed due to space/indent? Could you revert it?
 {code}
      @Override
                public String apply(@Nullable InetSocketAddress addr) {
                  assert addr != null;
                  return addr.getAddress().getHostAddress() + ":" + 
addr.getPort();
                }
              }));
{code}


* It'd be nice to have a default value here.
 {code}
<property>
2725      <name>dfs.namenode.hosts.provider.classname</name>
2726      <value></value>
{code}


Thanks!

> Provide support for upgrade domain script
> -----------------------------------------
>
>                 Key: HDFS-9005
>                 URL: https://issues.apache.org/jira/browse/HDFS-9005
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>            Reporter: Ming Ma
>            Assignee: Ming Ma
>         Attachments: HDFS-9005.patch
>
>
> As part of the upgrade domain feature, we need to provide a mechanism to 
> specify upgrade domain for each datanode. One way to accomplish that is to 
> allow admins specify an upgrade domain script that takes DN ip or hostname as 
> input and return the upgrade domain. Then namenode will use it at run time to 
> set {{DatanodeInfo}}'s upgrade domain string. The configuration can be 
> something like:
> {noformat}
> <property>
> <name>dfs.namenode.upgrade.domain.script.file.name</name>
> <value>/etc/hadoop/conf/upgrade-domain.sh</value>
> </property>
> {noformat}
> just like topology script, 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to