HDFS-11691. Add a proper scheme to the datanode links in NN web UI. Contributed by Kihwal Lee

(cherry picked from commit e4321ec843)
This commit is contained in:
Jason Lowe 2017-04-25 17:30:42 -05:00
parent d1da5ba3af
commit 31af85c18e
2 changed files with 3 additions and 3 deletions

View File

@ -319,7 +319,7 @@
{#LiveNodes}
<tr>
<td ng-value="{state}-{name}" class="dfshealth-node-icon dfshealth-node-{state}">{name} ({xferaddr})</td>
<td ng-value="{state}-{name}"><a href='//{dnWebAddress}'>{dnWebAddress}</a></td>
<td ng-value="{state}-{name}"><a href='{dnWebAddress}'>{dnWebAddress}</a></td>
<td ng-value="{lastContact}">{lastContact}s</td>
<td ng-value="{lastBlockReport}">{lastBlockReport}m</td>
<td ng-value="{usedPercentage}">

View File

@ -215,9 +215,9 @@
var port = n.infoAddr.split(":")[1];
var securePort = n.infoSecureAddr.split(":")[1];
var dnHost = n.name.split(":")[0];
n.dnWebAddress = dnHost + ":" + port;
n.dnWebAddress = "http://" + dnHost + ":" + port;
if (securePort != 0) {
n.dnWebAddress = dnHost + ":" + securePort;
n.dnWebAddress = "https://" + dnHost + ":" + securePort;
}
if (n.adminState === "In Service") {