hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lium...@apache.org
Subject [2/2] hadoop git commit: HDFS-11375. Display the volume storage type in datanode UI. Contributed by Surendra Singh Lilhore
Date Wed, 15 Feb 2017 20:41:56 GMT
HDFS-11375. Display the volume storage type in datanode UI. Contributed by Surendra Singh Lilhore

(cherry picked from commit 0741dd3b9abdeb65bb783c1a8b01f078c4bdba17)


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

Branch: refs/heads/branch-2
Commit: 96be70513a0b8e4ef27de58c0df0c1d560f28960
Parents: 323782b
Author: Mingliang Liu <liuml07@apache.org>
Authored: Wed Feb 15 11:37:26 2017 -0800
Committer: Mingliang Liu <liuml07@apache.org>
Committed: Wed Feb 15 12:34:43 2017 -0800

----------------------------------------------------------------------
 .../hadoop/hdfs/server/datanode/fsdataset/impl/FsDatasetImpl.java | 3 +++
 .../hadoop-hdfs/src/main/webapps/datanode/datanode.html           | 2 ++
 2 files changed, 5 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/96be7051/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/fsdataset/impl/FsDatasetImpl.java
----------------------------------------------------------------------
diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/fsdataset/impl/FsDatasetImpl.java
b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/fsdataset/impl/FsDatasetImpl.java
index cc1d0c1..3738f87 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/fsdataset/impl/FsDatasetImpl.java
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/fsdataset/impl/FsDatasetImpl.java
@@ -2793,6 +2793,7 @@ class FsDatasetImpl implements FsDatasetSpi<FsVolumeImpl> {
     final long reservedSpaceForReplicas; // size of space reserved RBW or
                                     // re-replication
     final long numBlocks;
+    final StorageType storageType;
 
     VolumeInfo(FsVolumeImpl v, long usedSpace, long freeSpace) {
       this.directory = v.toString();
@@ -2801,6 +2802,7 @@ class FsDatasetImpl implements FsDatasetSpi<FsVolumeImpl> {
       this.reservedSpace = v.getReserved();
       this.reservedSpaceForReplicas = v.getReservedForReplicas();
       this.numBlocks = v.getNumBlocks();
+      this.storageType = v.getStorageType();
     }
   }
 
@@ -2836,6 +2838,7 @@ class FsDatasetImpl implements FsDatasetSpi<FsVolumeImpl> {
       innerInfo.put("reservedSpace", v.reservedSpace);
       innerInfo.put("reservedSpaceForReplicas", v.reservedSpaceForReplicas);
       innerInfo.put("numBlocks", v.numBlocks);
+      innerInfo.put("storageType", v.storageType);
       info.put(v.directory, innerInfo);
     }
     return info;

http://git-wip-us.apache.org/repos/asf/hadoop/blob/96be7051/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/datanode/datanode.html
----------------------------------------------------------------------
diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/datanode/datanode.html b/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/datanode/datanode.html
index b35a0a7..e474ab5 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/datanode/datanode.html
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/webapps/datanode/datanode.html
@@ -100,6 +100,7 @@
   <thead>
     <tr>
       <th>Directory</th>
+      <th>StorageType</th>
       <th>Capacity Used</th>
       <th>Capacity Left</th>
       <th>Capacity Reserved</th>
@@ -110,6 +111,7 @@
   {#dn.VolumeInfo}
     <tr>
       <td>{name}</td>
+      <td>{storageType}</td>
       <td>{usedSpace|fmt_bytes}</td>
       <td>{freeSpace|fmt_bytes}</td>
       <td>{reservedSpace|fmt_bytes}</td>


---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org


Mime
View raw message