hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From whe...@apache.org
Subject hadoop git commit: HDFS-7953. NN Web UI fails to navigate to paths that contain #. Contributed by kanaka kumar avvaru.
Date Wed, 18 Mar 2015 18:08:51 GMT
Repository: hadoop
Updated Branches:
  refs/heads/branch-2.7 54e63c52c -> 5293ae031


HDFS-7953. NN Web UI fails to navigate to paths that contain #. Contributed by kanaka kumar
avvaru.


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/5293ae03
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/5293ae03
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/5293ae03

Branch: refs/heads/branch-2.7
Commit: 5293ae03118af75b55cbd33159ea3d8d84d680da
Parents: 54e63c5
Author: Haohui Mai <wheat9@apache.org>
Authored: Wed Mar 18 11:08:08 2015 -0700
Committer: Haohui Mai <wheat9@apache.org>
Committed: Wed Mar 18 11:08:49 2015 -0700

----------------------------------------------------------------------
 hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt           |  3 +++
 .../hadoop-hdfs/src/main/webapps/hdfs/explorer.js     | 14 +++++++-------
 2 files changed, 10 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/5293ae03/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
----------------------------------------------------------------------
diff --git a/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
index 5c486b0..6cdc21b 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
+++ b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
@@ -852,6 +852,9 @@ Release 2.7.0 - UNRELEASED
     HDFS-7946. TestDataNodeVolumeFailureReporting NPE on Windows. (Xiaoyu Yao
     via Arpit Agarwal)
 
+    HDFS-7953. NN Web UI fails to navigate to paths that contain #.
+    (kanaka kumar avvaru via wheat9)
+
     BREAKDOWN OF HDFS-7584 SUBTASKS AND RELATED JIRAS
 
       HDFS-7720. Quota by Storage Type API, tools and ClientNameNode

http://git-wip-us.apache.org/repos/asf/hadoop/blob/5293ae03/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/hdfs/explorer.js
----------------------------------------------------------------------
diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/hdfs/explorer.js b/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/hdfs/explorer.js
index 0a53dcd..131b2aa 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/hdfs/explorer.js
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/hdfs/explorer.js
@@ -78,6 +78,12 @@
     return data.RemoteException !== undefined ? data.RemoteException.message : "";
   }
 
+  function encode_path(abs_path) {
+    abs_path = encodeURIComponent(abs_path);
+    var re = /%2F/g;
+    return abs_path.replace(re, '/');
+  }
+
   function view_file_details(path, abs_path) {
     function show_block_info(blocks) {
       var menus = $('#file-info-blockinfo-list');
@@ -102,12 +108,6 @@
       menus.change();
     }
 
-    function encode_path(abs_path) {
-      abs_path = encodeURIComponent(abs_path);
-      var re = /%2F/g;
-      return abs_path.replace(re, '/');
-    }
-
     abs_path = encode_path(abs_path);
     var url = '/webhdfs/v1' + abs_path + '?op=GET_BLOCK_LOCATIONS';
     $.get(url).done(function(data) {
@@ -149,7 +149,7 @@
         return chunk.write('' + new Date(Number(value)).toLocaleString());
       }
     };
-    var url = '/webhdfs/v1' + dir + '?op=LISTSTATUS';
+    var url = '/webhdfs/v1' + encode_path(dir) + '?op=LISTSTATUS';
     $.get(url, function(data) {
       var d = get_response(data, "FileStatuses");
       if (d === null) {


Mime
View raw message