Package org.apache.hadoop.hbase
Class ClusterStatus
java.lang.Object
org.apache.hadoop.hbase.ClusterStatus
- All Implemented Interfaces:
ClusterMetrics
Deprecated.
Status information on the HBase cluster.
ClusterStatus provides clients with information such as:
- The count and names of region servers in the cluster.
- The count and names of dead region servers in the cluster.
- The name of the active master for the cluster.
- The name(s) of the backup master(s) for the cluster, if they exist.
- The average cluster load.
- The number of regions deployed on the cluster.
- The number of requests since last report.
- Detailed region server loading and resource usage information, per server and per region.
- Regions in transition at master
- The unique cluster ID
ClusterMetrics.Option
provides a way to get desired ClusterStatus information.
The following codes will get all the cluster information.
{ @code // 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:
{ @code Admin admin = connection.getAdmin(); ClusterStatus status = admin.getClusterStatus(EnumSet.of(Option.LIVE_SERVERS)); }
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.hadoop.hbase.ClusterMetrics
ClusterMetrics.Option
-
Field Summary
Modifier and TypeFieldDescriptionprivate final ClusterMetrics
Deprecated.private static final byte
Deprecated. -
Constructor Summary
ConstructorDescriptionClusterStatus
(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.0ClusterStatus
(ClusterMetrics metrics) Deprecated. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Deprecated.Deprecated.Returns the names of backup mastersDeprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetBackupMasterNames()
instead.int
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetBackupMasterNames()
instead.Deprecated.Deprecated.Deprecated.Returns the names of region servers on the dead listint
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 (HBASE-13656).int
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetDeadServerNames()
.Deprecated.Returns the HBase version string as reported by the HMasterlong
getLastMajorCompactionTsForRegion
(byte[] region) Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UseClusterMetrics.getLastMajorCompactionTimestamp(byte[])
instead.long
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UseClusterMetrics.getLastMajorCompactionTimestamp(TableName)
instead.private Map<ServerName,
ServerLoad> Deprecated.Deprecated.Returns the names of region servers on the live listgetLoad
(ServerName sn) Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetLiveServerMetrics()
instead.Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetMasterName()
instead.Deprecated.String[]
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetMasterCoprocessorNames()
instead.int
Deprecated.Deprecated.Returns detailed information about the current masterServerName
.Deprecated.Provide the list of master tasksint
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UseClusterMetrics.getRegionCount()
.Deprecated.int
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UseClusterMetrics.getRequestCount()
instead.Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetLiveServerMetrics()
instead.Deprecated.int
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetLiveServerMetrics()
.Deprecated.Provide region states count for given table.Deprecated.Returns the names of region servers on the unknown listbyte
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0int
hashCode()
Deprecated.boolean
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 No flag in 2.0toString()
Deprecated.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.apache.hadoop.hbase.ClusterMetrics
getAverageLoad, getLastMajorCompactionTimestamp, getLastMajorCompactionTimestamp, getRegionCount, getRequestCount
-
Field Details
-
VERSION
Deprecated.- See Also:
-
metrics
Deprecated.
-
-
Constructor Details
-
ClusterStatus
@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) Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 -
ClusterStatus
Deprecated.
-
-
Method Details
-
getDeadServerNames
Deprecated.Returns the names of region servers on the dead list- Specified by:
getDeadServerNames
in interfaceClusterMetrics
-
getUnknownServerNames
Deprecated.Description copied from interface:ClusterMetrics
Returns the names of region servers on the unknown list- Specified by:
getUnknownServerNames
in interfaceClusterMetrics
-
getLiveServerMetrics
Deprecated.Description copied from interface:ClusterMetrics
Returns the names of region servers on the live list- Specified by:
getLiveServerMetrics
in interfaceClusterMetrics
-
getServersSize
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetLiveServerMetrics()
.- Returns:
- the number of region servers in the cluster
-
getDeadServers
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 (HBASE-13656). UsegetDeadServerNames()
.- Returns:
- the number of dead region servers in the cluster
-
getDeadServersSize
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetDeadServerNames()
.- Returns:
- the number of dead region servers in the cluster
-
getRegionsCount
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UseClusterMetrics.getRegionCount()
.- Returns:
- the number of regions deployed on the cluster
-
getRequestsCount
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UseClusterMetrics.getRequestCount()
instead.- Returns:
- the number of requests since last report
-
getMasterName
Deprecated.Description copied from interface:ClusterMetrics
Returns detailed information about the current masterServerName
.- Specified by:
getMasterName
in interfaceClusterMetrics
- Returns:
- current master information if it exists
-
getBackupMasterNames
Deprecated.Description copied from interface:ClusterMetrics
Returns the names of backup masters- Specified by:
getBackupMasterNames
in interfaceClusterMetrics
-
getRegionStatesInTransition
Deprecated.- Specified by:
getRegionStatesInTransition
in interfaceClusterMetrics
-
getHBaseVersion
Deprecated.Returns the HBase version string as reported by the HMaster- Specified by:
getHBaseVersion
in interfaceClusterMetrics
-
getLiveServerLoads
Deprecated. -
equals
Deprecated. -
hashCode
Deprecated. -
getVersion
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0- Returns:
- the object version number
-
getServers
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetLiveServerMetrics()
instead. -
getMaster
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetMasterName()
instead.Returns detailed information about the current masterServerName
.- Returns:
- current master information if it exists
-
getBackupMastersSize
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetBackupMasterNames()
instead.- Returns:
- the number of backup masters in the cluster
-
getBackupMasters
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetBackupMasterNames()
instead.- Returns:
- the names of backup masters
-
getLoad
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetLiveServerMetrics()
instead.- Returns:
- Server's load or null if not found.
-
getClusterId
Deprecated.- Specified by:
getClusterId
in interfaceClusterMetrics
-
getMasterCoprocessorNames
Deprecated.- Specified by:
getMasterCoprocessorNames
in interfaceClusterMetrics
-
getMasterCoprocessors
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UsegetMasterCoprocessorNames()
instead.Get the list of master coprocessor names. -
getLastMajorCompactionTsForTable
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UseClusterMetrics.getLastMajorCompactionTimestamp(TableName)
instead.Get the last major compaction time for a given table. -
getLastMajorCompactionTsForRegion
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 UseClusterMetrics.getLastMajorCompactionTimestamp(byte[])
instead.Get the last major compaction time for a given region. -
isBalancerOn
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0 No flag in 2.0Returns true if the balancer is enabled. -
getBalancerOn
Deprecated.- Specified by:
getBalancerOn
in interfaceClusterMetrics
-
getMasterInfoPort
Deprecated.- Specified by:
getMasterInfoPort
in interfaceClusterMetrics
-
getServersName
Deprecated.- Specified by:
getServersName
in interfaceClusterMetrics
-
getTableRegionStatesCount
Deprecated.Description copied from interface:ClusterMetrics
Provide region states count for given table. e.g howmany regions of give table are opened/closed/rit etc- Specified by:
getTableRegionStatesCount
in interfaceClusterMetrics
- Returns:
- map of table to region states count
-
getMasterTasks
Deprecated.Description copied from interface:ClusterMetrics
Provide the list of master tasks- Specified by:
getMasterTasks
in interfaceClusterMetrics
-
toString
Deprecated.
-
ClusterMetrics
instead.