File tree Expand file tree Collapse file tree
hbase-server/src/main/resources/hbase-webapps/master Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2020<%@ page contentType =" text/html;charset=UTF-8"
2121 import =" java.util.*"
2222 import =" org.apache.hadoop.hbase.ServerName"
23- import =" org.apache.hadoop.hbase.master.HMaster"
24- import =" org.apache.hbase.thirdparty.com.google.common.base.Preconditions" %>
23+ import =" org.apache.hadoop.hbase.master.HMaster" %>
2524<%
2625 HMaster master = (HMaster ) getServletContext(). getAttribute(HMaster . MASTER );
2726 if (! master. isActiveMaster()) {
2827
2928 ServerName active_master = master. getActiveMaster(). orElse(null );
30- Preconditions . checkState(active_master != null , " Failed to retrieve active master's ServerName!" );
3129 int activeInfoPort = master. getActiveMasterInfoPort();
3230% >
3331 <div class =" row inner_header" >
3432 <div class =" page-header" >
3533 <h1 >Backup Master <small ><%= master. getServerName(). getHostname() % > </small ></h1 >
3634 </div >
3735 </div >
36+ <% if (active_master != null ) { % >
3837 <h4 >Current Active Master: <a href =" //<%= active_master. getHostname() % > :<%= activeInfoPort % > /master.jsp"
3938 target =" _blank" ><%= active_master. getHostname() % > </a ></h4 >
39+ <% } else { % >
40+ <div id =" initializing-info" >
41+ <h4 >Cluster is starting, active master not yet elected</h4 >
42+ <p >No active master has been found. This is normal during cluster startup or master failover.
43+ Please refresh manually in a few seconds.</p >
44+ </div >
45+ <% } % >
4046 <% } else { % >
4147 <h2 >Backup Masters</h2 >
4248
You can’t perform that action at this time.
0 commit comments