hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jxi...@apache.org
Subject svn commit: r1375673 - in /hbase/trunk/hbase-server/src/main: jamon/org/apache/hadoop/hbase/tmpl/master/MasterStatusTmpl.jamon java/org/apache/hadoop/hbase/master/HMaster.java
Date Tue, 21 Aug 2012 17:25:27 GMT
Author: jxiang
Date: Tue Aug 21 17:25:27 2012
New Revision: 1375673

URL: http://svn.apache.org/viewvc?rev=1375673&view=rev
Log:
HBASE-6607 NullPointerException when accessing master web ui while master is initializing

Modified:
    hbase/trunk/hbase-server/src/main/jamon/org/apache/hadoop/hbase/tmpl/master/MasterStatusTmpl.jamon
    hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java

Modified: hbase/trunk/hbase-server/src/main/jamon/org/apache/hadoop/hbase/tmpl/master/MasterStatusTmpl.jamon
URL: http://svn.apache.org/viewvc/hbase/trunk/hbase-server/src/main/jamon/org/apache/hadoop/hbase/tmpl/master/MasterStatusTmpl.jamon?rev=1375673&r1=1375672&r2=1375673&view=diff
==============================================================================
--- hbase/trunk/hbase-server/src/main/jamon/org/apache/hadoop/hbase/tmpl/master/MasterStatusTmpl.jamon
(original)
+++ hbase/trunk/hbase-server/src/main/jamon/org/apache/hadoop/hbase/tmpl/master/MasterStatusTmpl.jamon
Tue Aug 21 17:25:27 2012
@@ -120,7 +120,7 @@ org.apache.hadoop.hbase.HBaseConfigurati
           for details.
           </div>
         </%if>
-        <%if !catalogJanitorEnabled %>
+        <%if master.isInitialized() && !catalogJanitorEnabled %>
           <div class="alert alert-error">
           Please note that your cluster is running with the CatalogJanitor disabled. It can
be
           re-enabled from the hbase shell by running the command 'catalogjanitor_switch true'

Modified: hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
URL: http://svn.apache.org/viewvc/hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java?rev=1375673&r1=1375672&r2=1375673&view=diff
==============================================================================
--- hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java (original)
+++ hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java Tue
Aug 21 17:25:27 2012
@@ -1207,8 +1207,8 @@ Server {
   @Override
   public IsCatalogJanitorEnabledResponse isCatalogJanitorEnabled(RpcController c,
       IsCatalogJanitorEnabledRequest req) throws ServiceException {
-    return IsCatalogJanitorEnabledResponse.newBuilder().
-        setValue(catalogJanitorChore.getEnabled()).build();
+    boolean isEnabled = catalogJanitorChore != null ? catalogJanitorChore.getEnabled() :
false;
+    return IsCatalogJanitorEnabledResponse.newBuilder().setValue(isEnabled).build();
   }
 
   /**



Mime
View raw message