Index: core/src/main/resources/webapps/master/table.jsp =================================================================== --- core/src/main/resources/webapps/master/table.jsp (revision 934197) +++ core/src/main/resources/webapps/master/table.jsp (working copy) @@ -1,22 +1,16 @@ <%@ page contentType="text/html;charset=UTF-8" - import="java.io.IOException" import="java.util.Map" - import="java.net.URLEncoder" - import="org.apache.hadoop.io.Text" import="org.apache.hadoop.io.Writable" import="org.apache.hadoop.conf.Configuration" - import="org.apache.hadoop.hbase.HTableDescriptor" import="org.apache.hadoop.hbase.client.HTable" import="org.apache.hadoop.hbase.client.HBaseAdmin" import="org.apache.hadoop.hbase.HRegionInfo" import="org.apache.hadoop.hbase.HServerAddress" import="org.apache.hadoop.hbase.HServerInfo" - import="org.apache.hadoop.hbase.HBaseConfiguration" import="org.apache.hadoop.hbase.io.ImmutableBytesWritable" import="org.apache.hadoop.hbase.master.HMaster" import="org.apache.hadoop.hbase.master.MetaRegion" import="org.apache.hadoop.hbase.util.Bytes" - import="java.io.IOException" import="java.util.Map" import="org.apache.hadoop.hbase.HConstants"%><% HMaster master = (HMaster)getServletContext().getAttribute(HMaster.MASTER); @@ -28,7 +22,11 @@ master.getServerManager().getServerAddressToServerInfo(); String tableHeader = "
| Name | Region Server | Encoded Name | Start Key | End Key |
|---|
| Attribute Name | Value | Description |
|---|---|---|
| Enabled | <%= hbadmin.isTableEnabled(table.getTableName()) %> | Is the table enabled |
| Fragmentation | <%= frags.get(tableName) != null ? frags.get(tableName).intValue() + "%" : "n/a" %> | How fragmented is the table. After a major compaction it is 0%. |
| Attribute Name | +Value | +Description |
| Enabled | +<%= hbadmin.isTableEnabled(table.getTableName()) %> | +Is the table enabled | +
| Fragmentation | +<%= frags.get(tableName) != null ? frags.get(tableName).intValue() + "%" : "n/a" %> | +How fragmented is the table. After a major compaction it is 0%. | +
| Table | Frag. | Description |
|---|---|---|
| <%= Bytes.toString(HConstants.ROOT_TABLE_NAME) %> | -<%= frags.get("-ROOT-") != null ? frags.get("-ROOT-").intValue() + "%" : "n/a" %> | -The -ROOT- table holds references to all .META. regions. | +
| Table | +<% if (showFragmentation) { %> +Frag. | +<% } %> +Description |
| <%= Bytes.toString(HConstants.ROOT_TABLE_NAME) %> | +<% if (showFragmentation) { %> +<%= frags.get("-ROOT-") != null ? frags.get("-ROOT-").intValue() + "%" : "n/a" %> | +<% } %> +The -ROOT- table holds references to all .META. regions. | +
| <%= Bytes.toString(HConstants.META_TABLE_NAME) %> | -<%= frags.get(".META.") != null ? frags.get(".META.").intValue() + "%" : "n/a" %> | -The .META. table holds references to all User Table regions | +
| <%= Bytes.toString(HConstants.META_TABLE_NAME) %> | +<% if (showFragmentation) { %> +<%= frags.get(".META.") != null ? frags.get(".META.").intValue() + "%" : "n/a" %> | +<% } %> +The .META. table holds references to all User Table regions |
| Table | Frag. | Description |
|---|---|---|
| Table | +<% if (showFragmentation) { %> +Frag. | +<% } %> +Description | +
| ><%= htDesc.getNameAsString() %> | -<%= frags.get(htDesc.getNameAsString()) != null ? frags.get(htDesc.getNameAsString()).intValue() + "%" : "n/a" %> | -<%= htDesc.toString() %> | +
| ><%= htDesc.getNameAsString() %> | +<% if (showFragmentation) { %> +<%= frags.get(htDesc.getNameAsString()) != null ? frags.get(htDesc.getNameAsString()).intValue() + "%" : "n/a" %> | +<% } %> +<%= htDesc.toString() %> |