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

Todd Lipcon commented on HDFS-2767:
-----------------------------------

Hi Uma. I had started working on this before you posted your patch, but looks 
like we went a similar direction. The only suggestion I have is to make the 
interface an argument of the constructor rather than calling a setter after 
it's instantiated. I'll upload what I have - do you think you could make that 
change in your patch?

Also, regarding this section:
{code}
+        // TODO(HA): Need other way to create the proxy instance based on
+        // protocol here.
+        if (protocol != null && NamenodeProtocol.class.equals(protocol)) {
+          current.namenode = DFSUtil.createNamenodeWithNNProtocol(
+              current.address, conf);
+        } else {
{code}
I think you can remove the TODO and change the {{else}} to an {{else if}} to 
check for ClientProtocol, with a final {{else}} clause that throws an 
AssertionError or IllegalStateException.

Lastly, I think we do need to wire the {{ugi}} parameter in to 
{{createNamenodeWithNNProtocol}} or else after a failover the user accessing 
HDFS might accidentally switch!
                
> HA: ConfiguredFailoverProxyProvider should support NameNodeProtocol
> -------------------------------------------------------------------
>
>                 Key: HDFS-2767
>                 URL: https://issues.apache.org/jira/browse/HDFS-2767
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: ha, hdfs client
>    Affects Versions: HA branch (HDFS-1623)
>            Reporter: Uma Maheswara Rao G
>            Assignee: Todd Lipcon
>            Priority: Blocker
>         Attachments: HDFS-2767.patch, hdfs-2767-what-todd-had.txt
>
>
> Presentely ConfiguredFailoverProxyProvider supports ClinetProtocol.
> It should support NameNodeProtocol also, because Balancer uses 
> NameNodeProtocol for getting blocks.

--
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