From b1edddcf89a2524f75be5021404396a5bc3434bd Mon Sep 17 00:00:00 2001 From: zhangduo Date: Sat, 30 Mar 2019 09:34:47 +0800 Subject: [PATCH] Revert "HBASE-22073 /rits.jsp throws an exception if no procedure" This reverts commit 85c17e711cdeb14bbe008a0045ca2540d51df4eb. --- .../resources/hbase-webapps/master/rits.jsp | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/hbase-server/src/main/resources/hbase-webapps/master/rits.jsp b/hbase-server/src/main/resources/hbase-webapps/master/rits.jsp index ae5f25c4232..78bc32e370a 100644 --- a/hbase-server/src/main/resources/hbase-webapps/master/rits.jsp +++ b/hbase-server/src/main/resources/hbase-webapps/master/rits.jsp @@ -22,11 +22,10 @@ import="java.util.Collections" import="java.util.Comparator" import="java.util.List" - import="java.util.stream.Collectors" import="org.apache.hadoop.hbase.master.HMaster" import="org.apache.hadoop.hbase.master.assignment.RegionStateNode" - import="org.apache.hadoop.hbase.master.assignment.RegionTransitionProcedure" %> +<%@ page import="java.util.stream.Collectors" %> <% HMaster master = (HMaster) getServletContext().getAttribute(HMaster.MASTER); List rit = master.getAssignmentManager().getRegionsInTransition(); @@ -87,17 +86,8 @@ <%= regionStateNode.getRegionInfo().getEncodedName() %> <%= regionStateNode.getRegionInfo().getTable() %> <%= regionStateNode.getState() %> - <% - RegionTransitionProcedure procedure = regionStateNode.getProcedure(); - - if (procedure == null) { - %> - - - <% } else { %> - <%= procedure.getProcId() %> - <%= escapeXml(procedure.getState().toString() + (procedure.isBypass() ? "(Bypassed)" : "")) %> - <% } %> + <%= regionStateNode.getProcedure().getProcId() %> + <%= escapeXml(regionStateNode.getProcedure().getState().toString() + (regionStateNode.getProcedure().isBypass() ? "(Bypassed)" : "")) %> <% } %>

<%= rit.size() %> region(s) in transition.

@@ -127,4 +117,4 @@

-<% } %> +<% } %> \ No newline at end of file