ClusterMetrics instead.@InterfaceAudience.Public @Deprecated public class ClusterStatus extends Object implements ClusterMetrics
ClusterStatus provides clients with information such as:
ClusterMetrics.Option provides a way to get desired ClusterStatus information.
The following codes will get all the cluster information.
// Original version still works
Admin admin = connection.getAdmin();
ClusterStatus status = admin.getClusterStatus();
// or below, a new version which has the same effects
ClusterStatus status = admin.getClusterStatus(EnumSet.allOf(Option.class));
If information about live servers is the only wanted.
then codes in the following way:
Admin admin = connection.getAdmin();
ClusterStatus status = admin.getClusterStatus(EnumSet.of(Option.LIVE_SERVERS));
ClusterMetrics.Option| Modifier and Type | Field and Description |
|---|---|
private ClusterMetrics |
metrics
Deprecated.
|
private static byte |
VERSION
Deprecated.
|
| Constructor and Description |
|---|
ClusterStatus(ClusterMetrics metrics)
Deprecated.
|
ClusterStatus(String hbaseVersion,
String clusterid,
Map<ServerName,ServerLoad> servers,
Collection<ServerName> deadServers,
ServerName master,
Collection<ServerName> backupMasters,
List<RegionState> rit,
String[] masterCoprocessors,
Boolean balancerOn,
int masterInfoPort)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o)
Deprecated.
|
List<ServerName> |
getBackupMasterNames()
Deprecated.
|
List<ServerName> |
getBackupMasters()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
Use
getBackupMasterNames() instead. |
int |
getBackupMastersSize()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
Use
getBackupMasterNames() instead. |
Boolean |
getBalancerOn()
Deprecated.
|
String |
getClusterId()
Deprecated.
|
List<ServerName> |
getDeadServerNames()
Deprecated.
|
int |
getDeadServers()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
(HBASE-13656).
Use
getDeadServerNames(). |
int |
getDeadServersSize()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
Use
getDeadServerNames(). |
String |
getHBaseVersion()
Deprecated.
|
long |
getLastMajorCompactionTsForRegion(byte[] region)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
Use
ClusterMetrics.getLastMajorCompactionTimestamp(byte[]) instead. |
long |
getLastMajorCompactionTsForTable(TableName table)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
Use
ClusterMetrics.getLastMajorCompactionTimestamp(TableName) instead. |
private Map<ServerName,ServerLoad> |
getLiveServerLoads()
Deprecated.
|
Map<ServerName,ServerMetrics> |
getLiveServerMetrics()
Deprecated.
|
ServerLoad |
getLoad(ServerName sn)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
Use
getLiveServerMetrics() instead. |
ServerName |
getMaster()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
Use
getMasterName() instead. |
List<String> |
getMasterCoprocessorNames()
Deprecated.
|
String[] |
getMasterCoprocessors()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
Use
getMasterCoprocessorNames() instead. |
int |
getMasterInfoPort()
Deprecated.
|
ServerName |
getMasterName()
Deprecated.
Returns detailed information about the current master
ServerName. |
int |
getRegionsCount()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
Use
ClusterMetrics.getRegionCount(). |
List<RegionState> |
getRegionStatesInTransition()
Deprecated.
|
int |
getRequestsCount()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
Use
ClusterMetrics.getRequestCount() instead. |
Collection<ServerName> |
getServers()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
Use
getLiveServerMetrics() instead. |
List<ServerName> |
getServersName()
Deprecated.
|
int |
getServersSize()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
Use
getLiveServerMetrics(). |
Map<TableName,RegionStatesCount> |
getTableRegionStatesCount()
Deprecated.
Provide region states count for given table.
|
byte |
getVersion()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
|
int |
hashCode()
Deprecated.
|
boolean |
isBalancerOn()
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0
No flag in 2.0
|
String |
toString()
Deprecated.
|
clone, finalize, getClass, notify, notifyAll, wait, wait, waitgetAverageLoad, getLastMajorCompactionTimestamp, getLastMajorCompactionTimestamp, getRegionCount, getRequestCountprivate static final byte VERSION
private final ClusterMetrics metrics
@Deprecated public ClusterStatus(String hbaseVersion, String clusterid, Map<ServerName,ServerLoad> servers, Collection<ServerName> deadServers, ServerName master, Collection<ServerName> backupMasters, List<RegionState> rit, String[] masterCoprocessors, Boolean balancerOn, int masterInfoPort)
@InterfaceAudience.Private public ClusterStatus(ClusterMetrics metrics)
public List<ServerName> getDeadServerNames()
getDeadServerNames in interface ClusterMetricspublic Map<ServerName,ServerMetrics> getLiveServerMetrics()
getLiveServerMetrics in interface ClusterMetrics@Deprecated public int getServersSize()
getLiveServerMetrics().@Deprecated public int getDeadServers()
getDeadServerNames().@Deprecated public int getDeadServersSize()
getDeadServerNames().@Deprecated public int getRegionsCount()
ClusterMetrics.getRegionCount().@Deprecated public int getRequestsCount()
ClusterMetrics.getRequestCount() instead.@Nullable public ServerName getMasterName()
ClusterMetricsServerName.getMasterName in interface ClusterMetricspublic List<ServerName> getBackupMasterNames()
getBackupMasterNames in interface ClusterMetricspublic List<RegionState> getRegionStatesInTransition()
getRegionStatesInTransition in interface ClusterMetricspublic String getHBaseVersion()
getHBaseVersion in interface ClusterMetricsprivate Map<ServerName,ServerLoad> getLiveServerLoads()
@Deprecated public byte getVersion()
@Deprecated public Collection<ServerName> getServers()
getLiveServerMetrics() instead.@Deprecated public ServerName getMaster()
getMasterName() instead.ServerName.@Deprecated public int getBackupMastersSize()
getBackupMasterNames() instead.@Deprecated public List<ServerName> getBackupMasters()
getBackupMasterNames() instead.@Deprecated public ServerLoad getLoad(ServerName sn)
getLiveServerMetrics() instead.sn - public String getClusterId()
getClusterId in interface ClusterMetricspublic List<String> getMasterCoprocessorNames()
getMasterCoprocessorNames in interface ClusterMetrics@Deprecated public String[] getMasterCoprocessors()
getMasterCoprocessorNames() instead.@Deprecated public long getLastMajorCompactionTsForTable(TableName table)
ClusterMetrics.getLastMajorCompactionTimestamp(TableName) instead.@Deprecated public long getLastMajorCompactionTsForRegion(byte[] region)
ClusterMetrics.getLastMajorCompactionTimestamp(byte[]) instead.@Deprecated public boolean isBalancerOn()
public Boolean getBalancerOn()
getBalancerOn in interface ClusterMetricspublic int getMasterInfoPort()
getMasterInfoPort in interface ClusterMetricspublic List<ServerName> getServersName()
getServersName in interface ClusterMetricspublic Map<TableName,RegionStatesCount> getTableRegionStatesCount()
ClusterMetricsgetTableRegionStatesCount in interface ClusterMetricsCopyright © 2007–2020 The Apache Software Foundation. All rights reserved.