From 84eb0220a4fe418ac33edf1e183630810c314067 Mon Sep 17 00:00:00 2001 From: Michael Stack Date: Sat, 27 Mar 2021 20:35:20 -0700 Subject: [PATCH] HBASE-25695 Link to the filter on hbase:meta from user tables panel on master page (#3092) Signed-off-by: Nick Dimiduk --- .../hbase/tmpl/master/MasterStatusTmpl.jamon | 30 ++++++++++--------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/hbase-server/src/main/jamon/org/apache/hadoop/hbase/tmpl/master/MasterStatusTmpl.jamon b/hbase-server/src/main/jamon/org/apache/hadoop/hbase/tmpl/master/MasterStatusTmpl.jamon index 1b746928dd7..e3999878234 100644 --- a/hbase-server/src/main/jamon/org/apache/hadoop/hbase/tmpl/master/MasterStatusTmpl.jamon +++ b/hbase-server/src/main/jamon/org/apache/hadoop/hbase/tmpl/master/MasterStatusTmpl.jamon @@ -30,6 +30,7 @@ AssignmentManager assignmentManager = null; <%import> java.util.*; +java.net.URLEncoder; java.io.IOException; org.apache.hadoop.hbase.client.replication.ReplicationPeerConfigUtil; org.apache.hadoop.hbase.client.RegionInfo; @@ -604,7 +605,6 @@ AssignmentManager assignmentManager = master.getAssignmentManager(); CLOSED CLOSING OFFLINE - FAILED SPLIT Other @@ -624,37 +624,39 @@ AssignmentManager assignmentManager = master.getAssignmentManager(); int closingRegionsCount = tableRegions.get(RegionState.State.CLOSING).size(); int offlineRegionsCount = tableRegions.get(RegionState.State.OFFLINE).size(); int splitRegionsCount = tableRegions.get(RegionState.State.SPLIT).size(); - int failedRegionsCount = tableRegions.get(RegionState.State.FAILED_OPEN).size() - + tableRegions.get(RegionState.State.FAILED_CLOSE).size(); int otherRegionsCount = 0; for (List list: tableRegions.values()) { otherRegionsCount += list.size(); } // now subtract known states otherRegionsCount = otherRegionsCount - openRegionsCount - - failedRegionsCount - offlineRegionsCount - - splitRegionsCount - openingRegionsCount - - closedRegionsCount - closingRegionsCount; + - offlineRegionsCount - splitRegionsCount + - openingRegionsCount - closedRegionsCount + - closingRegionsCount; + String encodedTableName = URLEncoder.encode(tableName.getNameAsString()); <% tableName.getNamespaceAsString() %> - ><% tableName.getQualifierAsString() %> + ><% URLEncoder.encode(tableName.getQualifierAsString()) %> <%if (frags != null) %> <% frags.get(tableName.getNameAsString()) != null ? frags.get(tableName.getNameAsString()).intValue() + "%" : "n/a" %> <% tableState.getState() %> <% openRegionsCount %> - <%if (openingRegionsCount > 0) %> <% openingRegionsCount %> <%else><% openingRegionsCount %> - <% closedRegionsCount %> - <%if (closingRegionsCount > 0) %> <% closingRegionsCount %> <%else><% closingRegionsCount %> - <% offlineRegionsCount %> - <% failedRegionsCount %> - <% splitRegionsCount %> + <%if (openingRegionsCount > 0) %> <% openingRegionsCount %> <%else><% openingRegionsCount %> + <%if (closedRegionsCount > 0) %> <% closedRegionsCount %> <%else><% closedRegionsCount %> + <%if (closingRegionsCount > 0) %> <% closingRegionsCount %> <%else><% closingRegionsCount %> + <%if (offlineRegionsCount > 0) %> <% offlineRegionsCount %> <%else><% offlineRegionsCount %> + <%if (splitRegionsCount > 0) %> <% splitRegionsCount %> <%else><% splitRegionsCount %> <% otherRegionsCount %> <% htDesc.toStringCustomizedValues() %> -

<% tables.size() %> table(s) in set. [Details]

+

<% tables.size() %> table(s) in set. [Details]. Click count below to + see list of regions currently in 'state' designated by the column title. For 'Other' Region state, + browse to hbase:meta and adjust filter on 'Meta Entries' to + query on states other than those listed here. Queries may take a while if the hbase:meta table + is large.