From c245eceddad8883103df30bbff9a285798f29fdf Mon Sep 17 00:00:00 2001 From: Kihwal Lee Date: Thu, 22 Mar 2018 12:28:34 -0500 Subject: [PATCH] HDFS-13195. DataNode conf page cannot display the current value after reconfig. Contributed by maobaolong. (cherry picked from commit 66461ed98b0b2f630b682bff927dbd74c251c26e) --- .../hadoop/hdfs/server/datanode/web/DatanodeHttpServer.java | 1 + 1 file changed, 1 insertion(+) diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/web/DatanodeHttpServer.java b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/web/DatanodeHttpServer.java index 2e46b284ac6..0ce327a69e1 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/web/DatanodeHttpServer.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/web/DatanodeHttpServer.java @@ -120,6 +120,7 @@ public class DatanodeHttpServer implements Closeable { this.infoServer = builder.build(); + this.infoServer.setAttribute(HttpServer2.CONF_CONTEXT_ATTRIBUTE, conf); this.infoServer.setAttribute("datanode", datanode); this.infoServer.setAttribute(JspHelper.CURRENT_CONF, conf); this.infoServer.addServlet(null, "/blockScannerReport",