[ https://issues.apache.org/jira/browse/HDFS-14891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16948270#comment-16948270 ]
Xieming Li commented on HDFS-14891: ----------------------------------- [~tasanuma] [~elgoiri] I found a potential problem and I want to have your opinions. In my patch, the router will read the "dfs.http.policy" in its local hdfs-site.xml and determine if the scheme should be "http" or "https". This appears to be reasonable, because that's how `webAddress` is created. (see: NamenodeHeartbeatService#serviceInit) However, this approach would fail when router and namenodes of subclusters have a different setting on "dfs.http.policy". Please consider the following case: {code:java} Router (HTTPS, dfs.http.policy=HTTPS_ONLY) │ ├── SubCluster1 (HTTPS, dfs.http.policy=HTTPS_ONLY) │ ├── nn1 │ └── nn2 │ └── SubCluster2 (HTTP, dfs.http.policy=HTTP_ONLY) ├── nn1 └── nn2 {code} Here, according to the hdfs-site.xml setting on Router, HTTPS address (both scheme and webAddress) will be used for SubCluster2. While in reality, HTTP address should be used. To solve this problem, the webAddress and scheme should be acquired directly from NameNode, say, the JMX of NameNode. However, the JMX of NameNode does not reveal webAddress or secureWebAddress currently. IMO, unless having different http policy among NameNodes and router are common, it is not necessary to get information from each NameNode. What do you think. > RBF: namenode links in NameFederation Health page (federationhealth.html) > cannot use https scheme > -------------------------------------------------------------------------------------------------- > > Key: HDFS-14891 > URL: https://issues.apache.org/jira/browse/HDFS-14891 > Project: Hadoop HDFS > Issue Type: Sub-task > Components: rbf, ui > Reporter: Xieming Li > Assignee: Xieming Li > Priority: Major > Attachments: HDFS-14891.001.patch, HDFS-14891.patch > > > The scheme of links in federationhealth.html are hard coded as 'http'. > It should be set to 'https' when dfs.http.policy is HTTPS_ONLY > (HTTP_AND_HTTPS also, maybe) > > [https://github.com/apache/hadoop/blob/c99a12167ff9566012ef32104a3964887d62c899/hadoop-hdfs-project/hadoop-hdfs-rbf/src/main/webapps/router/federationhealth.html#L168-L169] > [https://github.com/apache/hadoop/blob/c99a12167ff9566012ef32104a3964887d62c899/hadoop-hdfs-project/hadoop-hdfs-rbf/src/main/webapps/router/federationhealth.html#L236] > -- This message was sent by Atlassian Jira (v8.3.4#803005) --------------------------------------------------------------------- To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org