From d4491114b4793a233b6c9953f39d1b9322a6361a Mon Sep 17 00:00:00 2001 From: Shuhei Yamasaki Date: Wed, 18 Dec 2019 17:33:17 -0500 Subject: [PATCH 1/3] [UI] Master UI shows long stack traces when table is broken --- .../resources/hbase-webapps/master/table.jsp | 32 ++++++++++++++++--- 1 file changed, 27 insertions(+), 5 deletions(-) diff --git a/hbase-server/src/main/resources/hbase-webapps/master/table.jsp b/hbase-server/src/main/resources/hbase-webapps/master/table.jsp index 81ef5621ca2c..380978da5392 100644 --- a/hbase-server/src/main/resources/hbase-webapps/master/table.jsp +++ b/hbase-server/src/main/resources/hbase-webapps/master/table.jsp @@ -383,11 +383,21 @@ if (fqtn != null && master.isInitialized()) { CompactionState compactionState = admin.getCompactionState(table.getName()).get(); %><%= compactionState %><% } catch (Exception e) { - // Nothing really to do here + // Nothing really to do here + %> + Unknown +
+ Show StackTrace +
+ <% } } else { %><%= CompactionState.NONE %><% @@ -834,10 +844,22 @@ if (withReplica) { <% } -} catch(Exception ex) { +} catch(Exception ex) { %> + Unknown Regions +
+ Show StackTrace +
+ + <% } finally { connection.close(); } From ee021f049f002c109d97b89bc751952e4d96d5bc Mon Sep 17 00:00:00 2001 From: YamasakiSS Date: Mon, 3 Feb 2020 03:45:38 +0900 Subject: [PATCH 2/3] fix conflict by delete finally section --- .../src/main/resources/hbase-webapps/master/table.jsp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/hbase-server/src/main/resources/hbase-webapps/master/table.jsp b/hbase-server/src/main/resources/hbase-webapps/master/table.jsp index 380978da5392..cda3148f9dcb 100644 --- a/hbase-server/src/main/resources/hbase-webapps/master/table.jsp +++ b/hbase-server/src/main/resources/hbase-webapps/master/table.jsp @@ -845,7 +845,7 @@ if (withReplica) { <% } } catch(Exception ex) { %> - Unknown Regions + Unknown Issue with Regions
Show StackTrace
@@ -860,8 +860,6 @@ if (withReplica) { %> <% -} finally { - connection.close(); } } // end else %> From 4fe61b91439009995e586931129fa0e31c64867f Mon Sep 17 00:00:00 2001 From: YamasakiSS Date: Mon, 3 Feb 2020 04:17:50 +0900 Subject: [PATCH 3/3] remove extra closing tag --- hbase-server/src/main/resources/hbase-webapps/master/table.jsp | 3 --- 1 file changed, 3 deletions(-) diff --git a/hbase-server/src/main/resources/hbase-webapps/master/table.jsp b/hbase-server/src/main/resources/hbase-webapps/master/table.jsp index cda3148f9dcb..603c1dc24b23 100644 --- a/hbase-server/src/main/resources/hbase-webapps/master/table.jsp +++ b/hbase-server/src/main/resources/hbase-webapps/master/table.jsp @@ -857,9 +857,6 @@ if (withReplica) { for(StackTraceElement element : ex.getStackTrace()) { %><%= StringEscapeUtils.escapeHtml4(element.toString() + "\n") %><% } - %> - - <% } } // end else %>