[ https://issues.apache.org/jira/browse/HDFS-13566?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16505083#comment-16505083 ]
Chen Liang commented on HDFS-13566: ----------------------------------- Post v002 patch to address the comments for a Jenkins check. Thanks for the review! Had an offline discussion with [~shv]. One key part was that we evaluated can we expose not only port, but also additional hostname/IP. But due to how Federation and HA works, this can become over-complicated. Will probably still only allow additional ports. Still need to revisit exactly how the configure entries should be exposed. Thanks [~xkrogen] for the detailed review, appreciated it! All comments addressed as suggested, except for a couple with following notes: {quote}Why the unnecessary cast to String on Server L1748? {quote} It is actually necessary because getNegotiatedProperty(...) returns as an object. I guess this javax API is designed to be generic, only under the context of Hadoop it is always a string. {quote}additionalListener is only set once, in the constructor. Let's make it final and remove all of the null checks {quote} Konstantin suggested setting it null in constructor, and only create it when there is actually an listener to add. So there are two places setting this null in the new patch now. {quote}Why don't we support multiple configured additional listeners in the constructor of NameNodeRpcServer ? Everywhere else in the code supports them, and it would be trivial to do so here. {quote} This is true. Still revisiting exactly how should configure entries be exposed, will update in the next update. {quote}TestDistributedFileSystem L430, why is it necessary to set "fs.defaultFS" {quote} It seemed if not set, a random port will be used. Setting this is to avoid the slim chance that the randomly chosen port happens to be 9001, which will collide with the configured additional port. There may be other ways to handle this, but I found this way the easiest. > Add configurable additional RPC listener to NameNode > ---------------------------------------------------- > > Key: HDFS-13566 > URL: https://issues.apache.org/jira/browse/HDFS-13566 > Project: Hadoop HDFS > Issue Type: Sub-task > Components: ipc > Reporter: Chen Liang > Assignee: Chen Liang > Priority: Major > Attachments: HDFS-13566.001.patch, HDFS-13566.002.patch > > > This Jira aims to add the capability to NameNode to run additional > listener(s). Such that NameNode can be accessed from multiple ports. > Fundamentally, this Jira tries to extend ipc.Server to allow configured with > more listeners, binding to different ports, but sharing the same call queue > and the handlers. Useful when different clients are only allowed to access > certain different ports. Combined with HDFS-13547, this also allows different > ports to have different SASL security levels. -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org