Modifier and Type | Field and Description |
---|---|
static List<ServerName> |
ServerName.EMPTY_SERVER_LIST |
Modifier and Type | Method and Description |
---|---|
ServerName |
ClusterStatus.getMaster()
Returns detailed information about the current master
ServerName . |
ServerName |
HBaseCluster.getServerHoldingMeta()
Get the ServerName of region server serving the first hbase:meta region
|
ServerName |
DistributedHBaseCluster.getServerHoldingRegion(TableName tn,
byte[] regionName) |
abstract ServerName |
HBaseCluster.getServerHoldingRegion(TableName tn,
byte[] regionName)
Get the ServerName of region server serving the specified region
|
ServerName |
MiniHBaseCluster.getServerHoldingRegion(TableName tn,
byte[] regionName) |
ServerName |
HRegionLocation.getServerName() |
ServerName |
RegionTransition.getServerName() |
ServerName |
Server.getServerName() |
ServerName |
SplitLogTask.getServerName() |
ServerName |
MockRegionServerServices.getServerName() |
static ServerName |
HRegionInfo.getServerName(Result r)
Deprecated.
use MetaTableAccessor methods for interacting with meta layouts
|
static ServerName |
ServerName.parseFrom(byte[] data)
Get a ServerName from the passed in data bytes.
|
static ServerName |
ServerName.parseServerName(String str) |
static ServerName |
ServerName.parseVersionedServerName(byte[] versionedBytes)
Use this method instantiating a
ServerName from bytes
gotten from a call to getVersionedBytes() . |
static ServerName |
ServerName.valueOf(String serverName)
Retrieve an instance of ServerName.
|
static ServerName |
ServerName.valueOf(String hostname,
int port,
long startcode)
Retrieve an instance of ServerName.
|
static ServerName |
ServerName.valueOf(String hostAndPort,
long startCode)
Retrieve an instance of ServerName.
|
Modifier and Type | Method and Description |
---|---|
Collection<ServerName> |
ClusterStatus.getBackupMasters() |
Collection<ServerName> |
ClusterStatus.getDeadServerNames() |
static Pair<HRegionInfo,ServerName> |
HRegionInfo.getHRegionInfoAndServerName(Result r)
Deprecated.
use MetaTableAccessor methods for interacting with meta layouts
|
static Pair<HRegionInfo,ServerName> |
MetaTableAccessor.getRegion(Connection connection,
byte[] regionName)
Deprecated.
|
Collection<ServerName> |
ClusterStatus.getServerInfo()
Deprecated.
As of release 0.92
(HBASE-1502).
This will be removed in HBase 2.0.0.
Use
ClusterStatus.getServers() . |
Collection<ServerName> |
ClusterStatus.getServers() |
static List<Pair<HRegionInfo,ServerName>> |
MetaTableAccessor.getTableRegionsAndLocations(ZooKeeperWatcher zkw,
Connection connection,
TableName tableName) |
static List<Pair<HRegionInfo,ServerName>> |
MetaTableAccessor.getTableRegionsAndLocations(ZooKeeperWatcher zkw,
Connection connection,
TableName tableName,
boolean excludeOfflinedSplitParents) |
Modifier and Type | Method and Description |
---|---|
static void |
MetaTableAccessor.addDaughter(Connection connection,
HRegionInfo regionInfo,
ServerName sn,
long openSeqNum)
Adds a daughter region entry to meta.
|
static Put |
MetaTableAccessor.addLocation(Put p,
ServerName sn,
long openSeqNum,
long time,
int replicaId) |
static void |
TestMetaTableAccessor.assertMetaLocation(Table meta,
byte[] row,
ServerName serverName,
long seqNum,
int replicaId,
boolean checkSeqNum) |
void |
HBaseTestingUtility.assertRegionOnlyOnServer(HRegionInfo hri,
ServerName server,
long timeout)
Check to make sure the region is open on the specified
region server, but not on any other one.
|
void |
HBaseTestingUtility.assertRegionOnServer(HRegionInfo hri,
ServerName server,
long timeout)
Due to async racing issue, a region may not be in
the online region list of a region server yet, after
the assignment znode is deleted and the new assignment
is recorded in master.
|
int |
ServerName.compareTo(ServerName other) |
static ZooKeeperWatcher |
HBaseTestingUtility.createAndForceNodeToOpenedState(HBaseTestingUtility TEST_UTIL,
HRegion region,
ServerName serverName)
Creates a znode with OPENED state.
|
static ZooKeeperWatcher |
HBaseTestingUtility.createAndForceNodeToOpenedState(HBaseTestingUtility TEST_UTIL,
Region region,
ServerName serverName)
Creates a znode with OPENED state.
|
RegionServerServices |
HBaseTestingUtility.createMockRegionServerService(ServerName name)
Create a stubbed out RegionServerService, mainly for getting FS.
|
static RegionTransition |
RegionTransition.createRegionTransition(EventType type,
byte[] regionName,
ServerName sn) |
static RegionTransition |
RegionTransition.createRegionTransition(EventType type,
byte[] regionName,
ServerName sn,
byte[] payload) |
AdminProtos.AdminService.BlockingInterface |
DistributedHBaseCluster.getAdminProtocol(ServerName serverName) |
abstract AdminProtos.AdminService.BlockingInterface |
HBaseCluster.getAdminProtocol(ServerName serverName)
Returns an AdminProtocol interface to the regionserver
|
AdminProtos.AdminService.BlockingInterface |
MiniHBaseCluster.getAdminProtocol(ServerName serverName) |
ClientProtos.ClientService.BlockingInterface |
DistributedHBaseCluster.getClientProtocol(ServerName serverName) |
abstract ClientProtos.ClientService.BlockingInterface |
HBaseCluster.getClientProtocol(ServerName serverName)
Returns a ClientProtocol interface to the regionserver
|
ClientProtos.ClientService.BlockingInterface |
MiniHBaseCluster.getClientProtocol(ServerName serverName) |
ServerLoad |
ClusterStatus.getLoad(ServerName sn) |
protected int |
MiniHBaseCluster.getMasterIndex(ServerName serverName) |
static Result |
MetaMockingUtil.getMetaTableRowResult(HRegionInfo region,
ServerName sn)
Returns a Result object constructed from the given region information simulating
a catalog table result.
|
static Result |
MetaMockingUtil.getMetaTableRowResult(HRegionInfo region,
ServerName sn,
HRegionInfo splita,
HRegionInfo splitb)
Returns a Result object constructed from the given region information simulating
a catalog table result.
|
static Result |
MetaMockingUtil.getMetaTableRowResultAsSplitRegion(HRegionInfo hri,
ServerName sn) |
protected int |
MiniHBaseCluster.getRegionServerIndex(ServerName serverName) |
static NavigableMap<HRegionInfo,Result> |
MetaTableAccessor.getServerUserRegions(Connection connection,
ServerName serverName) |
boolean |
SplitLogTask.isDone(ServerName sn) |
boolean |
SplitLogTask.isErr(ServerName sn) |
boolean |
SplitLogTask.isOwned(ServerName sn) |
boolean |
SplitLogTask.isResigned(ServerName sn) |
static boolean |
ServerName.isSameHostnameAndPort(ServerName left,
ServerName right) |
boolean |
SplitLogTask.isUnassigned(ServerName sn) |
void |
DistributedHBaseCluster.killMaster(ServerName serverName) |
abstract void |
HBaseCluster.killMaster(ServerName serverName)
Kills the master process if this is a distributed cluster, otherwise,
this causes master to exit doing basic clean up only.
|
void |
MiniHBaseCluster.killMaster(ServerName serverName) |
void |
DistributedHBaseCluster.killRegionServer(ServerName serverName) |
abstract void |
HBaseCluster.killRegionServer(ServerName serverName)
Kills the region server process if this is a distributed cluster, otherwise
this causes the region server to exit doing basic clean up only.
|
void |
MiniHBaseCluster.killRegionServer(ServerName serverName) |
static void |
MetaTableAccessor.mergeRegions(Connection connection,
HRegionInfo mergedRegion,
HRegionInfo regionA,
HRegionInfo regionB,
ServerName sn,
int regionReplication,
long masterSystemTime)
Merge the two regions into one in an atomic operation.
|
RegionLocations |
RegionLocations.removeByServer(ServerName serverName)
Returns a new RegionLocations with the locations removed (set to null)
which have the destination server as given.
|
boolean |
MockRegionServerServices.removeFromOnlineRegions(Region r,
ServerName destination) |
static void |
MetaTableAccessor.splitRegion(Connection connection,
HRegionInfo parent,
HRegionInfo splitA,
HRegionInfo splitB,
ServerName sn,
int regionReplication)
Splits the region into two in an atomic operation.
|
void |
DistributedHBaseCluster.stopMaster(ServerName serverName) |
abstract void |
HBaseCluster.stopMaster(ServerName serverName)
Stops the given master, by attempting a gradual stop.
|
void |
MiniHBaseCluster.stopMaster(ServerName serverName) |
void |
DistributedHBaseCluster.stopRegionServer(ServerName serverName) |
abstract void |
HBaseCluster.stopRegionServer(ServerName serverName)
Stops the given region server, by attempting a gradual stop.
|
void |
MiniHBaseCluster.stopRegionServer(ServerName serverName) |
static void |
MetaTableAccessor.updateRegionLocation(Connection connection,
HRegionInfo regionInfo,
ServerName sn,
long openSeqNum,
long masterSystemTime)
Updates the location of the specified region in hbase:meta to be the specified
server hostname and startcode.
|
void |
DistributedHBaseCluster.waitForMasterToStop(ServerName serverName,
long timeout) |
abstract void |
HBaseCluster.waitForMasterToStop(ServerName serverName,
long timeout)
Wait for the specified master to stop the thread / process.
|
void |
MiniHBaseCluster.waitForMasterToStop(ServerName serverName,
long timeout) |
void |
DistributedHBaseCluster.waitForRegionServerToStop(ServerName serverName,
long timeout) |
abstract void |
HBaseCluster.waitForRegionServerToStop(ServerName serverName,
long timeout)
Wait for the specified region server to stop the thread / process.
|
void |
MiniHBaseCluster.waitForRegionServerToStop(ServerName serverName,
long timeout) |
Constructor and Description |
---|
ClusterStatus(String hbaseVersion,
String clusterid,
Map<ServerName,ServerLoad> servers,
Collection<ServerName> deadServers,
ServerName master,
Collection<ServerName> backupMasters,
Map<String,RegionState> rit,
String[] masterCoprocessors,
Boolean balancerOn) |
Done(ServerName originServer,
ZooKeeperProtos.SplitLogTask.RecoveryMode mode) |
Err(ServerName originServer,
ZooKeeperProtos.SplitLogTask.RecoveryMode mode) |
HRegionLocation(HRegionInfo regionInfo,
ServerName serverName) |
HRegionLocation(HRegionInfo regionInfo,
ServerName serverName,
long seqNum) |
Owned(ServerName originServer,
ZooKeeperProtos.SplitLogTask.RecoveryMode mode) |
Resigned(ServerName originServer,
ZooKeeperProtos.SplitLogTask.RecoveryMode mode) |
Unassigned(ServerName originServer,
ZooKeeperProtos.SplitLogTask.RecoveryMode mode) |
Constructor and Description |
---|
ClusterStatus(String hbaseVersion,
String clusterid,
Map<ServerName,ServerLoad> servers,
Collection<ServerName> deadServers,
ServerName master,
Collection<ServerName> backupMasters,
Map<String,RegionState> rit,
String[] masterCoprocessors,
Boolean balancerOn) |
ClusterStatus(String hbaseVersion,
String clusterid,
Map<ServerName,ServerLoad> servers,
Collection<ServerName> deadServers,
ServerName master,
Collection<ServerName> backupMasters,
Map<String,RegionState> rit,
String[] masterCoprocessors,
Boolean balancerOn) |
ClusterStatus(String hbaseVersion,
String clusterid,
Map<ServerName,ServerLoad> servers,
Collection<ServerName> deadServers,
ServerName master,
Collection<ServerName> backupMasters,
Map<String,RegionState> rit,
String[] masterCoprocessors,
Boolean balancerOn) |
Modifier and Type | Field and Description |
---|---|
protected ServerName[] |
Action.initialServers |
Modifier and Type | Method and Description |
---|---|
protected ServerName[] |
Action.getCurrentServers()
Returns current region servers - active master
|
Modifier and Type | Method and Description |
---|---|
protected List<ServerName> |
RollingBatchRestartRsAction.selectServers() |
protected List<ServerName> |
RollingBatchRestartRsExceptMetaAction.selectServers() |
Modifier and Type | Method and Description |
---|---|
protected void |
Action.killMaster(ServerName server) |
protected void |
Action.killRs(ServerName server) |
protected void |
Action.startMaster(ServerName server) |
protected void |
Action.startRs(ServerName server) |
Modifier and Type | Method and Description |
---|---|
protected void |
Action.unbalanceRegions(ClusterStatus clusterStatus,
List<ServerName> fromServers,
List<ServerName> toServers,
double fractionOfRegions) |
protected void |
Action.unbalanceRegions(ClusterStatus clusterStatus,
List<ServerName> fromServers,
List<ServerName> toServers,
double fractionOfRegions) |
Modifier and Type | Field and Description |
---|---|
static ServerName |
TestClientNoCluster.META_SERVERNAME |
Modifier and Type | Method and Description |
---|---|
protected static ServerName |
TestFastFailWithoutTestUtil.getSomeServerName() |
Modifier and Type | Method and Description |
---|---|
static NavigableMap<HRegionInfo,ServerName> |
MetaScanner.allTableRegions(Configuration conf,
Connection connection,
TableName tableName,
boolean offlined)
Deprecated.
|
static NavigableMap<HRegionInfo,ServerName> |
MetaScanner.allTableRegions(Connection connection,
TableName tableName)
Lists all of the table regions currently in META.
|
NavigableMap<HRegionInfo,ServerName> |
HTable.getRegionLocations()
Deprecated.
This is no longer a public API. Use
HTable.getAllRegionLocations() instead. |
Modifier and Type | Method and Description |
---|---|
void |
MetaCache.cacheLocation(TableName tableName,
ServerName source,
HRegionLocation location)
Put a newly discovered HRegionLocation into the cache.
|
void |
MetaCache.clearCache(ServerName serverName)
Delete all cached entries of a server.
|
void |
MetaCache.clearCache(TableName tableName,
byte[] row,
ServerName serverName)
Delete a cached location for a table, row and server
|
void |
ClusterConnection.clearCaches(ServerName sn)
Clear any caches that pertain to server name
sn . |
void |
HConnection.clearCaches(ServerName sn)
Deprecated.
internal method, do not use thru HConnection
|
void |
Admin.closeRegion(ServerName sn,
HRegionInfo hri)
Close a region.
|
void |
HBaseAdmin.closeRegion(ServerName sn,
HRegionInfo hri)
Close a region.
|
void |
Admin.compactRegionServer(ServerName sn,
boolean major)
Compact all regions on the region server
|
void |
HBaseAdmin.compactRegionServer(ServerName sn,
boolean major)
Compact all regions on the region server
|
CoprocessorRpcChannel |
Admin.coprocessorService(ServerName sn)
Creates and returns a
com.google.protobuf.RpcChannel instance
connected to the passed region server. |
CoprocessorRpcChannel |
HBaseAdmin.coprocessorService(ServerName sn)
Creates and returns a
com.google.protobuf.RpcChannel instance
connected to the passed region server. |
BlockingRpcChannel |
TestClientTimeouts.RandomTimeoutRpcClient.createBlockingRpcChannel(ServerName sn,
User ticket,
int rpcTimeout) |
static ClusterConnection |
ConnectionUtils.createShortCircuitHConnection(Connection conn,
ServerName serverName,
AdminProtos.AdminService.BlockingInterface admin,
ClientProtos.ClientService.BlockingInterface client)
Adapt a HConnection so that it can bypass the RPC layer (serialization,
deserialization, networking, etc..) -- i.e.
|
AdminProtos.AdminService.BlockingInterface |
ClusterConnection.getAdmin(ServerName serverName)
Establishes a connection to the region server at the specified address.
|
AdminProtos.AdminService.BlockingInterface |
HConnection.getAdmin(ServerName serverName)
Deprecated.
internal method, do not use thru HConnection
|
AdminProtos.AdminService.BlockingInterface |
HConnection.getAdmin(ServerName serverName,
boolean getMaster)
Deprecated.
You can pass master flag but nothing special is done.
|
ClientProtos.ClientService.BlockingInterface |
ClusterConnection.getClient(ServerName serverName)
Establishes a connection to the region server at the specified address, and returns
a region client protocol.
|
ClientProtos.ClientService.BlockingInterface |
HConnection.getClient(ServerName serverName)
Deprecated.
internal method, do not use thru HConnection
|
ClientProtos.ClientService.BlockingInterface |
CoprocessorHConnection.getClient(ServerName serverName) |
static ClusterConnection |
HConnectionTestingUtility.getMockedConnectionAndDecorate(Configuration conf,
AdminProtos.AdminService.BlockingInterface admin,
ClientProtos.ClientService.BlockingInterface client,
ServerName sn,
HRegionInfo hri)
Calls
HConnectionTestingUtility.getMockedConnection(Configuration) and then mocks a few
more of the popular ClusterConnection methods so they do 'normal'
operation (see return doc below for list). |
List<HRegionInfo> |
Admin.getOnlineRegions(ServerName sn)
Get all the online regions on a region server.
|
List<HRegionInfo> |
HBaseAdmin.getOnlineRegions(ServerName sn)
Get all the online regions on a region server.
|
ServerStatistics |
ServerStatisticTracker.getStats(ServerName server) |
boolean |
ClusterConnection.isDeadServer(ServerName serverName)
Deprecated.
internal method, do not use thru HConnection
|
boolean |
HConnection.isDeadServer(ServerName serverName)
Deprecated.
internal method, do not use thru HConnection
|
void |
Admin.rollWALWriter(ServerName serverName)
Roll the log writer.
|
void |
HBaseAdmin.rollWALWriter(ServerName serverName) |
void |
HBaseAdmin.split(ServerName sn,
HRegionInfo hri,
byte[] splitPoint) |
void |
ClusterConnection.updateCachedLocations(TableName tableName,
byte[] regionName,
byte[] rowkey,
Object exception,
ServerName source)
Update the location cache.
|
void |
HConnection.updateCachedLocations(TableName tableName,
byte[] regionName,
byte[] rowkey,
Object exception,
ServerName source)
Deprecated.
internal method, do not use thru HConnection
|
void |
Admin.updateConfiguration(ServerName server)
Update the configuration and trigger an online config change
on the regionserver
|
void |
HBaseAdmin.updateConfiguration(ServerName server) |
void |
ServerStatisticTracker.updateRegionStats(ServerName server,
byte[] region,
ClientProtos.RegionLoadStats currentStats) |
static <T> T |
ResultStatsUtil.updateStats(T r,
ServerStatisticTracker serverStats,
ServerName server,
byte[] regionName)
Update the stats for the specified region if the result is an instance of
ResultStatsUtil |
Modifier and Type | Method and Description |
---|---|
long |
ClientBackoffPolicy.getBackoffTime(ServerName serverName,
byte[] region,
ServerStatistics stats) |
long |
ClientBackoffPolicyFactory.NoBackoffPolicy.getBackoffTime(ServerName serverName,
byte[] region,
ServerStatistics stats) |
long |
ExponentialClientBackoffPolicy.getBackoffTime(ServerName serverName,
byte[] region,
ServerStatistics stats) |
Modifier and Type | Method and Description |
---|---|
ServerName |
OpenRegionCoordination.OpenRegionDetails.getServerName() |
ServerName |
SplitLogManagerCoordination.SplitLogManagerDetails.getServerName() |
ServerName |
ZkOpenRegionCoordination.ZkOpenRegionDetails.getServerName() |
Modifier and Type | Method and Description |
---|---|
protected static int |
ZkSplitLogWorkerCoordination.attemptToOwnTask(boolean isFirstTime,
ZooKeeperWatcher zkw,
ServerName server,
String task,
ZooKeeperProtos.SplitLogTask.RecoveryMode mode,
int taskZKVersion)
Try to own the task by transitioning the zk node data from UNASSIGNED to OWNED.
|
void |
RegionMergeCoordination.confirmRegionMergeTransaction(HRegionInfo merged,
HRegionInfo a,
HRegionInfo b,
ServerName serverName,
RegionMergeCoordination.RegionMergeDetails rmd)
Confirm that the region merge can be performed
|
void |
ZkRegionMergeCoordination.confirmRegionMergeTransaction(HRegionInfo merged,
HRegionInfo a,
HRegionInfo b,
ServerName serverName,
RegionMergeCoordination.RegionMergeDetails rmd) |
ZKSplitLogManagerCoordination.TaskFinisher.Status |
ZKSplitLogManagerCoordination.TaskFinisher.finish(ServerName workerName,
String taskname)
finish the partially done task.
|
void |
SplitLogManagerCoordination.markRegionsRecovering(ServerName serverName,
Set<HRegionInfo> userRegions)
Mark regions in recovering state for distributed log replay
|
void |
ZKSplitLogManagerCoordination.markRegionsRecovering(ServerName serverName,
Set<HRegionInfo> userRegions)
Create znodes /hbase/recovering-regions/[region_ids...]/[failed region server names ...] for
all regions of the passed in region servers
|
void |
RegionMergeCoordination.processRegionMergeRequest(HRegionInfo merged,
HRegionInfo a,
HRegionInfo b,
ServerName serverName,
RegionMergeCoordination.RegionMergeDetails rmd) |
void |
ZkRegionMergeCoordination.processRegionMergeRequest(HRegionInfo p,
HRegionInfo hri_a,
HRegionInfo hri_b,
ServerName sn,
RegionMergeCoordination.RegionMergeDetails rmd) |
int |
SplitTransactionCoordination.processTransition(HRegionInfo p,
HRegionInfo hri_a,
HRegionInfo hri_b,
ServerName sn,
SplitTransactionCoordination.SplitTransactionDetails std)
Required by AssignmentManager
|
int |
ZKSplitTransactionCoordination.processTransition(HRegionInfo p,
HRegionInfo hri_a,
HRegionInfo hri_b,
ServerName sn,
SplitTransactionCoordination.SplitTransactionDetails std) |
void |
CloseRegionCoordination.setClosedState(HRegion region,
ServerName sn,
CloseRegionCoordination.CloseRegionDetails crd)
Called after region is closed to notify all interesting parties / "register"
region as finally closed.
|
void |
ZkCloseRegionCoordination.setClosedState(HRegion region,
ServerName sn,
CloseRegionCoordination.CloseRegionDetails crd)
In ZK-based version we do some znodes transitioning.
|
void |
OpenRegionCoordination.OpenRegionDetails.setServerName(ServerName serverName)
Sets server name on which opening operation is running.
|
void |
ZkOpenRegionCoordination.ZkOpenRegionDetails.setServerName(ServerName serverName) |
void |
RegionMergeCoordination.startRegionMergeTransaction(HRegionInfo region,
ServerName serverName,
HRegionInfo a,
HRegionInfo b)
Start the region merge transaction
|
void |
ZkRegionMergeCoordination.startRegionMergeTransaction(HRegionInfo region,
ServerName serverName,
HRegionInfo a,
HRegionInfo b)
Creates a new ephemeral node in the PENDING_MERGE state for the merged region.
|
void |
SplitTransactionCoordination.startSplitTransaction(HRegion parent,
ServerName serverName,
HRegionInfo hri_a,
HRegionInfo hri_b)
init coordination for split transaction
|
void |
ZKSplitTransactionCoordination.startSplitTransaction(HRegion parent,
ServerName serverName,
HRegionInfo hri_a,
HRegionInfo hri_b)
Creates a new ephemeral node in the PENDING_SPLIT state for the specified region.
|
Constructor and Description |
---|
SplitLogManagerDetails(ConcurrentMap<String,SplitLogManager.Task> tasks,
MasterServices master,
Set<String> failedDeletions,
ServerName serverName) |
Modifier and Type | Method and Description |
---|---|
void |
BaseMasterAndRegionObserver.postMove(ObserverContext<MasterCoprocessorEnvironment> ctx,
HRegionInfo region,
ServerName srcServer,
ServerName destServer) |
void |
BaseMasterObserver.postMove(ObserverContext<MasterCoprocessorEnvironment> ctx,
HRegionInfo region,
ServerName srcServer,
ServerName destServer) |
void |
MasterObserver.postMove(ObserverContext<MasterCoprocessorEnvironment> ctx,
HRegionInfo region,
ServerName srcServer,
ServerName destServer)
Called after the region move has been requested.
|
void |
TestMasterObserver.CPMasterObserver.postMove(ObserverContext<MasterCoprocessorEnvironment> env,
HRegionInfo region,
ServerName srcServer,
ServerName destServer) |
void |
BaseMasterAndRegionObserver.preMove(ObserverContext<MasterCoprocessorEnvironment> ctx,
HRegionInfo region,
ServerName srcServer,
ServerName destServer) |
void |
BaseMasterObserver.preMove(ObserverContext<MasterCoprocessorEnvironment> ctx,
HRegionInfo region,
ServerName srcServer,
ServerName destServer) |
void |
MasterObserver.preMove(ObserverContext<MasterCoprocessorEnvironment> ctx,
HRegionInfo region,
ServerName srcServer,
ServerName destServer)
Called prior to moving a given region from one region server to another.
|
void |
TestMasterObserver.CPMasterObserver.preMove(ObserverContext<MasterCoprocessorEnvironment> env,
HRegionInfo region,
ServerName srcServer,
ServerName destServer) |
Modifier and Type | Method and Description |
---|---|
ServerName |
RegionMovedException.getServerName() |
Constructor and Description |
---|
PreemptiveFastFailException(long count,
long timeOfFirstFailureMilliSec,
long timeOfLatestAttemptMilliSec,
ServerName serverName) |
RegionMovedException(ServerName serverName,
long locationSeqNum) |
Modifier and Type | Method and Description |
---|---|
void |
AsyncRpcClient.cancelConnections(ServerName sn)
Interrupt the connections to the given ip:port server.
|
void |
RpcClient.cancelConnections(ServerName sn)
Interrupt the connections to the given server.
|
void |
RpcClientImpl.cancelConnections(ServerName sn)
Interrupt the connections to the given ip:port server.
|
BlockingRpcChannel |
AbstractRpcClient.createBlockingRpcChannel(ServerName sn,
User ticket,
int defaultOperationTimeout) |
BlockingRpcChannel |
RpcClient.createBlockingRpcChannel(ServerName sn,
User user,
int rpcTimeout)
Creates a "channel" that can be used by a blocking protobuf service.
|
RpcChannel |
AsyncRpcClient.createRpcChannel(ServerName sn,
User user,
int rpcTimeout)
Creates a "channel" that can be used by a protobuf service.
|
Constructor and Description |
---|
BlockingRpcChannelImplementation(AbstractRpcClient rpcClient,
ServerName sn,
User ticket,
int channelOperationTimeout) |
RegionServerCoprocessorRpcChannel(ClusterConnection conn,
ServerName serverName) |
RpcChannelImplementation(AsyncRpcClient rpcClient,
ServerName sn,
User ticket,
int channelOperationTimeout) |
Modifier and Type | Field and Description |
---|---|
ServerName |
SplitLogManager.Task.cur_worker_name |
static ServerName |
AssignmentManager.HBCK_CODE_SERVERNAME |
Modifier and Type | Method and Description |
---|---|
ServerName |
RegionPlan.getDestination()
Get the destination server for the plan for this region.
|
ServerName |
RegionStates.getRegionServerOfRegion(HRegionInfo hri) |
ServerName |
RegionState.getServerName() |
ServerName |
HMaster.getServerName() |
ServerName |
TestActiveMasterManager.DummyMaster.getServerName() |
ServerName |
RegionPlan.getSource()
Get the source server for the plan for this region.
|
ServerName |
LoadBalancer.randomAssignment(HRegionInfo regionInfo,
List<ServerName> servers)
Get a random region server from the list
|
ServerName |
TestAssignmentManager.MockedLoadBalancer.randomAssignment(HRegionInfo regionInfo,
List<ServerName> servers) |
Modifier and Type | Method and Description |
---|---|
List<Pair<ServerName,Long>> |
DeadServer.copyDeadServersSince(long ts)
Extract all the servers dead since a given time, and sort them.
|
Set<ServerName> |
DeadServer.copyServerNames() |
List<ServerName> |
ServerManager.createDestinationServersList()
Calls
ServerManager.createDestinationServersList(org.apache.hadoop.hbase.ServerName) without server to exclude. |
List<ServerName> |
ServerManager.createDestinationServersList(ServerName serverToExclude)
Creates a list of possible destinations for a region.
|
protected List<ServerName> |
ClusterStatusPublisher.generateDeadServersListToSend()
Create the dead server to send.
|
protected Map<TableName,Map<ServerName,List<HRegionInfo>>> |
RegionStates.getAssignmentsByTable()
This is an EXPENSIVE clone.
|
protected List<Pair<ServerName,Long>> |
ClusterStatusPublisher.getDeadServers(long since)
Get the servers which died since a given timestamp.
|
List<ServerName> |
ServerManager.getDrainingServersList() |
static List<ServerName> |
RegionPlacementMaintainer.getFavoredNodeList(String favoredNodesStr) |
Map<ServerName,ServerLoad> |
ServerManager.getOnlineServers() |
List<ServerName> |
ServerManager.getOnlineServersList() |
Map<HRegionInfo,ServerName> |
RegionStates.getRegionAssignments() |
protected Map<ServerName,List<HRegionInfo>> |
RegionStates.getRegionAssignmentsByServer()
Returns a clone of region assignments per server
|
Map<ServerName,List<HRegionInfo>> |
SnapshotOfRegionAssignmentFromMeta.getRegionServerToRegionMap()
Get regionserver to region map
|
Map<HRegionInfo,ServerName> |
SnapshotOfRegionAssignmentFromMeta.getRegionToRegionServerMap()
Get region to region server map
|
Map<ServerName,List<HRegionInfo>> |
AssignmentManager.getSnapShotOfAssignment(Collection<HRegionInfo> infos) |
Map<HRegionInfo,ServerName> |
LoadBalancer.immediateAssignment(List<HRegionInfo> regions,
List<ServerName> servers)
Sync assign a region
|
Map<ServerName,List<HRegionInfo>> |
LoadBalancer.retainAssignment(Map<HRegionInfo,ServerName> regions,
List<ServerName> servers)
Assign regions to the previously hosting region server
|
Map<ServerName,List<HRegionInfo>> |
TestAssignmentManager.MockedLoadBalancer.retainAssignment(Map<HRegionInfo,ServerName> regions,
List<ServerName> servers) |
Map<ServerName,List<HRegionInfo>> |
LoadBalancer.roundRobinAssignment(List<HRegionInfo> regions,
List<ServerName> servers)
Perform a Round Robin assignment of regions.
|
Modifier and Type | Method and Description |
---|---|
void |
DeadServer.add(ServerName sn)
Adds the server to the dead server list if it's not there already.
|
boolean |
ServerManager.addServerToDrainList(ServerName sn) |
void |
DeadServer.cleanAllPreviousInstances(ServerName newServerName) |
boolean |
DeadServer.cleanPreviousInstance(ServerName newServerName)
A dead server that comes back alive has a different start code.
|
static void |
ServerManager.closeRegionSilentlyAndWait(ClusterConnection connection,
ServerName server,
HRegionInfo region,
long timeout)
Contacts a region server and waits up to timeout ms
to close the region.
|
List<ServerName> |
ServerManager.createDestinationServersList(ServerName serverToExclude)
Creates a list of possible destinations for a region.
|
RegionState |
RegionStates.createRegionState(HRegionInfo hri,
RegionState.State newState,
ServerName serverName,
ServerName lastHost)
Add a region to RegionStates with the specified state.
|
static TableLockManager |
TableLockManager.createTableLockManager(Configuration conf,
ZooKeeperWatcher zkWatcher,
ServerName serverName)
Creates and returns a TableLockManager according to the configuration
|
void |
AssignmentManager.deleteClosingOrClosedNode(HRegionInfo region,
ServerName sn) |
void |
ServerManager.expireServer(ServerName serverName) |
void |
DeadServer.finish(ServerName sn) |
ServerLoad |
ServerManager.getLoad(ServerName serverName) |
String |
RackManager.getRack(ServerName server)
Get the name of the rack containing a server, according to the DNS to
switch mapping.
|
int |
HMaster.getRegionServerInfoPort(ServerName sn) |
Set<HRegionInfo> |
RegionStates.getServerRegions(ServerName serverName)
Get a copy of all regions assigned to a server
|
Date |
DeadServer.getTimeOfDeath(ServerName deadServerName)
Get the time when a server died
|
void |
SplitLogManager.Task.heartbeat(long time,
int version,
ServerName worker) |
AssignmentManager.ServerHostRegion |
AssignmentManager.isCarryingMeta(ServerName serverName) |
AssignmentManager.ServerHostRegion |
AssignmentManager.isCarryingMetaReplica(ServerName serverName,
HRegionInfo metaHri) |
AssignmentManager.ServerHostRegion |
AssignmentManager.isCarryingMetaReplica(ServerName serverName,
int replicaId) |
boolean |
DeadServer.isDeadServer(ServerName serverName) |
boolean |
RegionState.isOnServer(ServerName sn) |
boolean |
RegionState.isOpenOrMergingNewOnServer(ServerName sn) |
boolean |
RegionState.isOpenOrMergingOnServer(ServerName sn) |
boolean |
RegionState.isOpenOrSplittingNewOnServer(ServerName sn) |
boolean |
RegionState.isOpenOrSplittingOnServer(ServerName sn) |
boolean |
RegionState.isPendingCloseOrClosingOnServer(ServerName sn) |
boolean |
RegionState.isPendingOpenOrOpeningOnServer(ServerName sn) |
boolean |
ServerManager.isServerDead(ServerName serverName)
Check if a server is known to be dead.
|
boolean |
ServerManager.isServerOnline(ServerName serverName) |
boolean |
ServerManager.isServerReachable(ServerName server)
Check if a region server is reachable and has the expected start code
|
void |
RegionStates.logSplit(ServerName serverName)
A dead server's wals have been split so that all the regions
used to be open on it can be safely assigned now.
|
void |
SplitLogManager.markRegionsRecovering(ServerName server,
Set<HRegionInfo> userRegions) |
protected String |
AssignmentManager.onRegionTransition(ServerName serverName,
RegionServerStatusProtos.RegionStateTransition transition)
Try to update some region states.
|
void |
MasterCoprocessorHost.postMove(HRegionInfo region,
ServerName srcServer,
ServerName destServer) |
boolean |
MasterCoprocessorHost.preMove(HRegionInfo region,
ServerName srcServer,
ServerName destServer) |
void |
MasterFileSystem.prepareLogReplay(ServerName serverName,
Set<HRegionInfo> regions)
Mark regions in recovering state when distributedLogReplay are set true
|
void |
ServerManager.processDeadServer(ServerName serverName) |
void |
ServerManager.processDeadServer(ServerName serverName,
boolean shouldSplitWal) |
List<HRegionInfo> |
AssignmentManager.processServerShutdown(ServerName sn)
Process shutdown server removing any assignments.
|
void |
LoadBalancer.regionOnline(HRegionInfo regionInfo,
ServerName sn)
Marks the region as online at balancer.
|
void |
RegionStates.regionOnline(HRegionInfo hri,
ServerName serverName) |
void |
RegionStates.regionOnline(HRegionInfo hri,
ServerName serverName,
long openSeqNum)
A region is online, won't be in transition any more.
|
void |
AssignmentListener.regionOpened(HRegionInfo regionInfo,
ServerName serverName)
The region was opened on the specified server.
|
boolean |
ServerManager.removeServerFromDrainList(ServerName sn) |
boolean |
ServerManager.sendRegionClose(ServerName server,
HRegionInfo region,
int versionOfClosingNode) |
boolean |
ServerManager.sendRegionClose(ServerName server,
HRegionInfo region,
int versionOfClosingNode,
ServerName dest,
boolean transitionInZK)
Sends an CLOSE RPC to the specified server to close the specified region.
|
RegionOpeningState |
ServerManager.sendRegionOpen(ServerName server,
HRegionInfo region,
int versionOfOfflineNode,
List<ServerName> favoredNodes)
Sends an OPEN RPC to the specified server to open the specified region.
|
List<RegionOpeningState> |
ServerManager.sendRegionOpen(ServerName server,
List<Triple<HRegionInfo,Integer,List<ServerName>>> regionOpenInfos)
Sends an OPEN RPC to the specified server to open the specified region.
|
void |
ServerManager.sendRegionsMerge(ServerName server,
HRegionInfo region_a,
HRegionInfo region_b,
boolean forcible)
Sends an MERGE REGIONS RPC to the specified server to merge the specified
regions.
|
void |
ServerManager.sendRegionWarmup(ServerName server,
HRegionInfo region)
Sends a WARMUP RPC to the specified server to warmup the specified region.
|
void |
ServerListener.serverAdded(ServerName serverName)
The server has joined the cluster.
|
List<HRegionInfo> |
RegionStates.serverOffline(ZooKeeperWatcher watcher,
ServerName sn)
A server is offline, all regions on it are dead.
|
void |
ServerListener.serverRemoved(ServerName serverName)
The server was removed from the cluster.
|
void |
RegionPlan.setDestination(ServerName dest)
Set the destination server for the plan for this region.
|
void |
MasterFileSystem.splitLog(ServerName serverName) |
void |
MasterFileSystem.splitMetaLog(ServerName serverName)
Specialized method to handle the splitting for meta WAL
|
RegionState |
RegionStates.transitionOpenFromPendingOpenOrOpeningOnServer(RegionTransition transition,
RegionState fromState,
ServerName sn)
Transition a region state to OPEN from OPENING/PENDING_OPEN
|
void |
AssignmentManager.unassign(HRegionInfo region,
boolean force,
ServerName dest)
Unassigns the specified region.
|
RegionState |
RegionStates.updateRegionState(HRegionInfo hri,
RegionState.State state,
ServerName serverName)
Update a region state.
|
protected boolean |
AssignmentManager.wasRegionOnDeadServerByMeta(HRegionInfo region,
ServerName sn) |
Modifier and Type | Method and Description |
---|---|
void |
AssignmentManager.assign(Map<HRegionInfo,ServerName> regions)
Assigns specified regions retaining assignments, if any.
|
List<RegionPlan> |
LoadBalancer.balanceCluster(Map<ServerName,List<HRegionInfo>> clusterState)
Perform the major balance operation
|
List<String> |
RackManager.getRack(List<ServerName> servers)
Same as
RackManager.getRack(ServerName) except that a list is passed |
Map<HRegionInfo,ServerName> |
LoadBalancer.immediateAssignment(List<HRegionInfo> regions,
List<ServerName> servers)
Sync assign a region
|
ServerName |
LoadBalancer.randomAssignment(HRegionInfo regionInfo,
List<ServerName> servers)
Get a random region server from the list
|
ServerName |
TestAssignmentManager.MockedLoadBalancer.randomAssignment(HRegionInfo regionInfo,
List<ServerName> servers) |
Map<ServerName,List<HRegionInfo>> |
LoadBalancer.retainAssignment(Map<HRegionInfo,ServerName> regions,
List<ServerName> servers)
Assign regions to the previously hosting region server
|
Map<ServerName,List<HRegionInfo>> |
LoadBalancer.retainAssignment(Map<HRegionInfo,ServerName> regions,
List<ServerName> servers)
Assign regions to the previously hosting region server
|
Map<ServerName,List<HRegionInfo>> |
TestAssignmentManager.MockedLoadBalancer.retainAssignment(Map<HRegionInfo,ServerName> regions,
List<ServerName> servers) |
Map<ServerName,List<HRegionInfo>> |
TestAssignmentManager.MockedLoadBalancer.retainAssignment(Map<HRegionInfo,ServerName> regions,
List<ServerName> servers) |
Map<ServerName,List<HRegionInfo>> |
LoadBalancer.roundRobinAssignment(List<HRegionInfo> regions,
List<ServerName> servers)
Perform a Round Robin assignment of regions.
|
RegionOpeningState |
ServerManager.sendRegionOpen(ServerName server,
HRegionInfo region,
int versionOfOfflineNode,
List<ServerName> favoredNodes)
Sends an OPEN RPC to the specified server to open the specified region.
|
List<RegionOpeningState> |
ServerManager.sendRegionOpen(ServerName server,
List<Triple<HRegionInfo,Integer,List<ServerName>>> regionOpenInfos)
Sends an OPEN RPC to the specified server to open the specified region.
|
void |
MasterFileSystem.splitLog(Set<ServerName> serverNames) |
void |
MasterFileSystem.splitLog(Set<ServerName> serverNames,
PathFilter filter)
This method is the base split method that splits WAL files matching a filter.
|
long |
SplitLogManager.splitLogDistributed(Set<ServerName> serverNames,
List<Path> logDirs,
PathFilter filter)
The caller will block until all the hbase:meta log files of the given region server have been
processed - successfully split or an error is encountered - by an available worker region
server.
|
void |
MasterFileSystem.splitMetaLog(Set<ServerName> serverNames)
Specialized method to handle the splitting for meta WAL
|
Constructor and Description |
---|
DummyMaster(ZooKeeperWatcher zk,
ServerName master) |
RegionPlan(HRegionInfo hri,
ServerName source,
ServerName dest)
Instantiate a plan for a region move, moving the specified region from
the specified source server to the specified destination server.
|
RegionState(HRegionInfo region,
RegionState.State state,
long stamp,
ServerName serverName) |
RegionState(HRegionInfo region,
RegionState.State state,
ServerName serverName) |
SplitLogManager(Server server,
Configuration conf,
Stoppable stopper,
MasterServices master,
ServerName serverName)
Its OK to construct this object even when region-servers are not online.
|
WaitToBeMasterThread(ZooKeeperWatcher zk,
ServerName address) |
Constructor and Description |
---|
BulkReOpen(Server server,
Map<ServerName,List<HRegionInfo>> serverToRegions,
AssignmentManager am) |
GeneralBulkAssigner(Server server,
Map<ServerName,List<HRegionInfo>> bulkPlan,
AssignmentManager am,
boolean waitTillAllAssigned) |
Modifier and Type | Field and Description |
---|---|
protected ServerName |
BaseLoadBalancer.masterServerName |
Modifier and Type | Method and Description |
---|---|
static ServerName[] |
FavoredNodeAssignmentHelper.getFavoredNodesList(byte[] favoredNodes) |
ServerName |
BaseLoadBalancer.randomAssignment(HRegionInfo regionInfo,
List<ServerName> servers)
Used to assign a single region to a random server.
|
ServerName |
FavoredNodeLoadBalancer.randomAssignment(HRegionInfo regionInfo,
List<ServerName> servers) |
Modifier and Type | Method and Description |
---|---|
protected Map<ServerName,List<HRegionInfo>> |
BaseLoadBalancer.assignMasterRegions(Collection<HRegionInfo> regions,
List<ServerName> servers)
Assign the regions that should be on master regionserver.
|
Map<HRegionInfo,List<ServerName>> |
FavoredNodesPlan.getAssignmentMap() |
List<ServerName> |
FavoredNodeLoadBalancer.getFavoredNodes(HRegionInfo regionInfo) |
List<ServerName> |
FavoredNodesPlan.getFavoredNodes(HRegionInfo region) |
protected Map<ServerName,List<HRegionInfo>> |
BaseLoadBalancer.getRegionAssignmentsByServer(Collection<HRegionInfo> regions) |
Map<HRegionInfo,ServerName> |
BaseLoadBalancer.immediateAssignment(List<HRegionInfo> regions,
List<ServerName> servers)
Generates an immediate assignment plan to be used by a new master for
regions in transition that do not have an already known destination.
|
protected TreeMap<ServerName,List<HRegionInfo>> |
BalancerTestBase.mockClusterServers(int[] mockCluster) |
protected TreeMap<ServerName,List<HRegionInfo>> |
BalancerTestBase.mockClusterServers(int[] mockCluster,
int numTables) |
Map<ServerName,List<HRegionInfo>> |
BaseLoadBalancer.retainAssignment(Map<HRegionInfo,ServerName> regions,
List<ServerName> servers)
Generates a bulk assignment startup plan, attempting to reuse the existing
assignment information from META, but adjusting for the specified list of
available/online servers available for assignment.
|
Map<ServerName,List<HRegionInfo>> |
BaseLoadBalancer.roundRobinAssignment(List<HRegionInfo> regions,
List<ServerName> servers)
Generates a bulk assignment plan to be used on cluster startup using a
simple round-robin assignment.
|
Map<ServerName,List<HRegionInfo>> |
FavoredNodeLoadBalancer.roundRobinAssignment(List<HRegionInfo> regions,
List<ServerName> servers) |
Modifier and Type | Method and Description |
---|---|
static FavoredNodesPlan.Position |
FavoredNodesPlan.getFavoredServerPosition(List<ServerName> favoredNodes,
ServerName server)
Return the position of the server in the favoredNodes list.
|
void |
BaseLoadBalancer.regionOnline(HRegionInfo regionInfo,
ServerName sn) |
protected void |
BalancerTestBase.returnServer(ServerName server) |
protected void |
BalancerTestBase.updateLoad(Map<ServerName,org.apache.hadoop.hbase.master.balancer.ServerAndLoad> map,
ServerName sn,
int diff) |
Modifier and Type | Method and Description |
---|---|
void |
BalancerTestBase.assertRegionReplicaPlacement(Map<ServerName,List<HRegionInfo>> serverMap,
RackManager rackManager)
Checks whether region replicas are not hosted on the same host.
|
protected Map<ServerName,List<HRegionInfo>> |
BaseLoadBalancer.assignMasterRegions(Collection<HRegionInfo> regions,
List<ServerName> servers)
Assign the regions that should be on master regionserver.
|
List<RegionPlan> |
FavoredNodeLoadBalancer.balanceCluster(Map<ServerName,List<HRegionInfo>> clusterState) |
List<RegionPlan> |
SimpleLoadBalancer.balanceCluster(Map<ServerName,List<HRegionInfo>> clusterMap)
Generate a global load balancing plan according to the specified map of
server information to the most loaded regions of each server.
|
List<RegionPlan> |
StochasticLoadBalancer.balanceCluster(Map<ServerName,List<HRegionInfo>> clusterState)
Given the cluster state this will try and approach an optimal balance.
|
List<RegionPlan> |
TestBaseLoadBalancer.MockBalancer.balanceCluster(Map<ServerName,List<HRegionInfo>> clusterState) |
protected List<RegionPlan> |
BaseLoadBalancer.balanceMasterRegions(Map<ServerName,List<HRegionInfo>> clusterMap)
Balance the regions that should be on master regionserver.
|
protected List<org.apache.hadoop.hbase.master.balancer.ServerAndLoad> |
BalancerTestBase.convertToList(Map<ServerName,List<HRegionInfo>> servers) |
protected BaseLoadBalancer.Cluster |
BaseLoadBalancer.createCluster(List<ServerName> servers,
Collection<HRegionInfo> regions) |
static byte[] |
FavoredNodeAssignmentHelper.getFavoredNodes(List<ServerName> serverAddrList) |
static String |
FavoredNodeAssignmentHelper.getFavoredNodesAsString(List<ServerName> nodes) |
static FavoredNodesPlan.Position |
FavoredNodesPlan.getFavoredServerPosition(List<ServerName> favoredNodes,
ServerName server)
Return the position of the server in the favoredNodes list.
|
Map<HRegionInfo,ServerName> |
BaseLoadBalancer.immediateAssignment(List<HRegionInfo> regions,
List<ServerName> servers)
Generates an immediate assignment plan to be used by a new master for
regions in transition that do not have an already known destination.
|
Map<HRegionInfo,ServerName[]> |
FavoredNodeAssignmentHelper.placeSecondaryAndTertiaryWithRestrictions(Map<HRegionInfo,ServerName> primaryRSMap)
For regions that share the primary, avoid placing the secondary and tertiary
on a same RS.
|
ServerName |
BaseLoadBalancer.randomAssignment(HRegionInfo regionInfo,
List<ServerName> servers)
Used to assign a single region to a random server.
|
ServerName |
FavoredNodeLoadBalancer.randomAssignment(HRegionInfo regionInfo,
List<ServerName> servers) |
protected List<org.apache.hadoop.hbase.master.balancer.ServerAndLoad> |
BalancerTestBase.reconcile(List<org.apache.hadoop.hbase.master.balancer.ServerAndLoad> list,
List<RegionPlan> plans,
Map<ServerName,List<HRegionInfo>> servers)
This assumes the RegionPlan HSI instances are the same ones in the map, so
actually no need to even pass in the map, but I think it's clearer.
|
Map<ServerName,List<HRegionInfo>> |
BaseLoadBalancer.retainAssignment(Map<HRegionInfo,ServerName> regions,
List<ServerName> servers)
Generates a bulk assignment startup plan, attempting to reuse the existing
assignment information from META, but adjusting for the specified list of
available/online servers available for assignment.
|
Map<ServerName,List<HRegionInfo>> |
BaseLoadBalancer.retainAssignment(Map<HRegionInfo,ServerName> regions,
List<ServerName> servers)
Generates a bulk assignment startup plan, attempting to reuse the existing
assignment information from META, but adjusting for the specified list of
available/online servers available for assignment.
|
protected void |
BalancerTestBase.returnServers(List<ServerName> servers) |
Map<ServerName,List<HRegionInfo>> |
BaseLoadBalancer.roundRobinAssignment(List<HRegionInfo> regions,
List<ServerName> servers)
Generates a bulk assignment plan to be used on cluster startup using a
simple round-robin assignment.
|
Map<ServerName,List<HRegionInfo>> |
FavoredNodeLoadBalancer.roundRobinAssignment(List<HRegionInfo> regions,
List<ServerName> servers) |
protected void |
TestStochasticLoadBalancer.testWithCluster(Map<ServerName,List<HRegionInfo>> serverMap,
RackManager rackManager,
boolean assertFullyBalanced,
boolean assertFullyBalancedForReplicas) |
void |
FavoredNodesPlan.updateAssignmentPlan(HRegionInfo region,
List<ServerName> servers)
Add an assignment to the plan
|
void |
FavoredNodesPlan.updateFavoredNodesMap(HRegionInfo region,
List<ServerName> servers)
Add an assignment to the plan
|
protected void |
BalancerTestBase.updateLoad(Map<ServerName,org.apache.hadoop.hbase.master.balancer.ServerAndLoad> map,
ServerName sn,
int diff) |
static void |
FavoredNodeAssignmentHelper.updateMetaWithFavoredNodesInfo(Map<HRegionInfo,List<ServerName>> regionToFavoredNodes,
Configuration conf)
Update meta table with favored nodes info
|
static void |
FavoredNodeAssignmentHelper.updateMetaWithFavoredNodesInfo(Map<HRegionInfo,List<ServerName>> regionToFavoredNodes,
Connection connection)
Update meta table with favored nodes info
|
Constructor and Description |
---|
Cluster(Collection<HRegionInfo> unassignedRegions,
Map<ServerName,List<HRegionInfo>> clusterState,
Map<String,Deque<RegionLoad>> loads,
org.apache.hadoop.hbase.master.balancer.RegionLocationFinder regionFinder,
RackManager rackManager) |
Cluster(Map<ServerName,List<HRegionInfo>> clusterState,
Map<String,Deque<RegionLoad>> loads,
org.apache.hadoop.hbase.master.balancer.RegionLocationFinder regionFinder,
RackManager rackManager) |
ClusterLoadState(Map<ServerName,List<HRegionInfo>> clusterState) |
FavoredNodeAssignmentHelper(List<ServerName> servers,
Configuration conf) |
Modifier and Type | Field and Description |
---|---|
protected ServerName |
ServerShutdownHandler.serverName |
Constructor and Description |
---|
LogReplayHandler(Server server,
MasterServices services,
DeadServer deadServers,
ServerName serverName) |
MetaServerShutdownHandler(Server server,
MasterServices services,
DeadServer deadServers,
ServerName serverName) |
ServerShutdownHandler(Server server,
MasterServices services,
DeadServer deadServers,
ServerName serverName,
boolean shouldSplitWal) |
Modifier and Type | Method and Description |
---|---|
void |
DisabledTableSnapshotHandler.snapshotRegions(List<Pair<HRegionInfo,ServerName>> regionsAndLocations) |
protected void |
EnabledTableSnapshotHandler.snapshotRegions(List<Pair<HRegionInfo,ServerName>> regions)
This method kicks off a snapshot procedure.
|
protected abstract void |
TakeSnapshotHandler.snapshotRegions(List<Pair<HRegionInfo,ServerName>> regions)
Snapshot the specified regions
|
Modifier and Type | Method and Description |
---|---|
static ServerName |
ProtobufUtil.toServerName(HBaseProtos.ServerName proto)
Convert a protocol buffer ServerName to a ServerName
|
Modifier and Type | Method and Description |
---|---|
static AdminProtos.CloseRegionRequest |
RequestConverter.buildCloseRegionRequest(ServerName server,
byte[] regionName,
boolean transitionInZK)
Create a CloseRegionRequest for a given region name
|
static AdminProtos.CloseRegionRequest |
RequestConverter.buildCloseRegionRequest(ServerName server,
byte[] regionName,
int versionOfClosingNode,
ServerName destinationServer,
boolean transitionInZK) |
static AdminProtos.CloseRegionRequest |
RequestConverter.buildCloseRegionRequest(ServerName server,
String encodedRegionName,
boolean transitionInZK)
Create a CloseRegionRequest for a given encoded region name
|
static AdminProtos.GetServerInfoResponse |
ResponseConverter.buildGetServerInfoResponse(ServerName serverName,
int webuiPort)
A utility to build a GetServerInfoResponse.
|
static AdminProtos.OpenRegionRequest |
RequestConverter.buildOpenRegionRequest(ServerName server,
HRegionInfo region,
int versionOfOfflineNode,
List<ServerName> favoredNodes,
Boolean openForReplay)
Create a protocol buffer OpenRegionRequest for a given region
|
static AdminProtos.OpenRegionRequest |
RequestConverter.buildOpenRegionRequest(ServerName server,
List<Triple<HRegionInfo,Integer,List<ServerName>>> regionOpenInfos,
Boolean openForReplay)
Create a protocol buffer OpenRegionRequest to open a list of regions
|
static void |
ProtobufUtil.closeRegion(AdminProtos.AdminService.BlockingInterface admin,
ServerName server,
byte[] regionName,
boolean transitionInZK)
A helper to close a region given a region name
using admin protocol.
|
static boolean |
ProtobufUtil.closeRegion(AdminProtos.AdminService.BlockingInterface admin,
ServerName server,
byte[] regionName,
int versionOfClosingNode,
ServerName destinationServer,
boolean transitionInZK)
A helper to close a region given a region name
using admin protocol.
|
static void |
ProtobufUtil.openRegion(AdminProtos.AdminService.BlockingInterface admin,
ServerName server,
HRegionInfo region)
A helper to open a region using admin protocol.
|
static WALProtos.RegionEventDescriptor |
ProtobufUtil.toRegionEventDescriptor(WALProtos.RegionEventDescriptor.EventType eventType,
HRegionInfo hri,
long seqId,
ServerName server,
Map<byte[],List<Path>> storeFiles) |
static HBaseProtos.ServerName |
ProtobufUtil.toServerName(ServerName serverName)
Convert a ServerName to a protocol buffer ServerName
|
Modifier and Type | Method and Description |
---|---|
static AdminProtos.OpenRegionRequest |
RequestConverter.buildOpenRegionRequest(ServerName server,
HRegionInfo region,
int versionOfOfflineNode,
List<ServerName> favoredNodes,
Boolean openForReplay)
Create a protocol buffer OpenRegionRequest for a given region
|
static AdminProtos.OpenRegionRequest |
RequestConverter.buildOpenRegionRequest(ServerName server,
List<Triple<HRegionInfo,Integer,List<ServerName>>> regionOpenInfos,
Boolean openForReplay)
Create a protocol buffer OpenRegionRequest to open a list of regions
|
static AdminProtos.UpdateFavoredNodesRequest |
RequestConverter.buildUpdateFavoredNodesRequest(List<Pair<HRegionInfo,List<ServerName>>> updateRegionInfos)
Create a protocol buffer UpdateFavoredNodesRequest to update a list of favorednode mappings
|
Modifier and Type | Field and Description |
---|---|
protected ServerName |
HRegionServer.serverName
The server name the Master sees us as.
|
Modifier and Type | Method and Description |
---|---|
protected ServerName |
HRegionServer.createRegionServerStatusStub()
Get the current master from ZooKeeper and open the RPC connection to it.
|
protected ServerName |
TestRegionServerReportForDuty.MyRegionServer.createRegionServerStatusStub() |
ServerName |
HRegionServer.getServerName() |
Modifier and Type | Method and Description |
---|---|
Put |
RegionMergeTransactionImpl.addLocation(Put p,
ServerName sn,
long openSeqNum) |
Put |
SplitTransactionImpl.addLocation(Put p,
ServerName sn,
long openSeqNum) |
protected void |
HRegionServer.addToMovedRegions(String encodedName,
ServerName destination,
long closeSeqNum) |
protected boolean |
HRegionServer.closeRegion(String encodedName,
boolean abort,
CloseRegionCoordination.CloseRegionDetails crd,
ServerName sn)
Close asynchronously a region, can be called from the master or internally by the regionserver
when stopping.
|
void |
RegionMergeTransactionImpl.prepareMutationsForMerge(HRegionInfo mergedRegion,
HRegionInfo regionA,
HRegionInfo regionB,
ServerName serverName,
List<Mutation> mutations,
int regionReplication) |
boolean |
HRegionServer.removeFromOnlineRegions(Region r,
ServerName destination) |
boolean |
OnlineRegions.removeFromOnlineRegions(Region r,
ServerName destination)
This method removes Region corresponding to hri from the Map of onlineRegions.
|
Constructor and Description |
---|
CloseRegionHandler(Server server,
RegionServerServices rsServices,
HRegionInfo regionInfo,
boolean abort,
CloseRegionCoordination closeRegionCoordination,
CloseRegionCoordination.CloseRegionDetails crd,
EventType eventType,
ServerName destination) |
CloseRegionHandler(Server server,
RegionServerServices rsServices,
HRegionInfo regionInfo,
boolean abort,
CloseRegionCoordination closeRegionCoordination,
CloseRegionCoordination.CloseRegionDetails crd,
ServerName destination) |
Modifier and Type | Method and Description |
---|---|
protected static List<ServerName> |
HBaseReplicationEndpoint.fetchSlavesAddresses(ZooKeeperWatcher zkw)
Get the list of all the region servers from the specified peer
|
List<ServerName> |
HBaseReplicationEndpoint.getRegionServers()
Get a list of all the addresses of all the region servers
for this peer cluster
|
Modifier and Type | Method and Description |
---|---|
void |
HBaseReplicationEndpoint.setRegionServers(List<ServerName> regionServers)
Set the list of region servers for that peer
|
Constructor and Description |
---|
SinkPeer(ServerName serverName,
AdminProtos.AdminService.BlockingInterface regionServer) |
Modifier and Type | Method and Description |
---|---|
void |
AccessController.preMove(ObserverContext<MasterCoprocessorEnvironment> c,
HRegionInfo region,
ServerName srcServer,
ServerName destServer) |
Modifier and Type | Method and Description |
---|---|
ServerName |
MockServer.getServerName() |
Modifier and Type | Method and Description |
---|---|
void |
HBaseFsck.HbckInfo.addServer(HRegionInfo hri,
ServerName server) |
void |
HBaseFsck.TableInfo.addServer(ServerName server) |
static void |
HBaseFsckRepair.closeRegionSilentlyAndWait(HConnection connection,
ServerName server,
HRegionInfo region)
Contacts a region server and waits up to hbase.hbck.close.timeout ms
(default 120s) to close the region.
|
Modifier and Type | Method and Description |
---|---|
static void |
HBaseFsckRepair.fixMetaHoleOnlineAndAddReplicas(Configuration conf,
HRegionInfo hri,
Collection<ServerName> servers,
int numReplicas)
Puts the specified HRegionInfo into META with replica related columns
|
static void |
HBaseFsckRepair.fixMultiAssignment(HConnection connection,
HRegionInfo region,
List<ServerName> servers)
Fix multiple assignment by doing silent closes on each RS hosting the region
and then force ZK unassigned node to OFFLINE to trigger assignment by
master.
|
Modifier and Type | Method and Description |
---|---|
static ServerName |
DefaultWALProvider.getServerNameFromWALDirectoryName(Configuration conf,
String path)
Pulls a ServerName out of a Path generated according to our layout rules.
|
static ServerName |
DefaultWALProvider.getServerNameFromWALDirectoryName(Path logFile)
This function returns region server name from a log file name which is in one of the following
formats:
hdfs://
|
Modifier and Type | Method and Description |
---|---|
ServerName |
MetaTableLocator.blockUntilAvailable(ZooKeeperWatcher zkw,
int replicaId,
long timeout)
Wait until the meta region is available and is not in transition.
|
ServerName |
MetaTableLocator.blockUntilAvailable(ZooKeeperWatcher zkw,
long timeout)
Wait until the meta region is available and is not in transition.
|
ServerName |
MasterAddressTracker.getMasterAddress()
Get the address of the current master if one is available.
|
ServerName |
MasterAddressTracker.getMasterAddress(boolean refresh)
Get the address of the current master if one is available.
|
static ServerName |
MasterAddressTracker.getMasterAddress(ZooKeeperWatcher zkw)
Get master address.
|
ServerName |
MetaTableLocator.getMetaRegionLocation(ZooKeeperWatcher zkw)
Gets the meta region location, if available.
|
ServerName |
MetaTableLocator.getMetaRegionLocation(ZooKeeperWatcher zkw,
int replicaId)
Gets the meta region location, if available.
|
ServerName |
MetaTableLocator.waitMetaRegionLocation(ZooKeeperWatcher zkw,
int replicaId,
long timeout)
Gets the meta region location, if available, and waits for up to the
specified timeout if not immediately available.
|
ServerName |
MetaTableLocator.waitMetaRegionLocation(ZooKeeperWatcher zkw,
long timeout)
Gets the meta region location, if available, and waits for up to the
specified timeout if not immediately available.
|
Modifier and Type | Method and Description |
---|---|
List<ServerName> |
MetaTableLocator.blockUntilAvailable(ZooKeeperWatcher zkw,
long timeout,
Configuration conf)
Wait until the primary meta region is available.
|
List<Pair<HRegionInfo,ServerName>> |
MetaTableLocator.getMetaRegionsAndLocations(ZooKeeperWatcher zkw) |
List<Pair<HRegionInfo,ServerName>> |
MetaTableLocator.getMetaRegionsAndLocations(ZooKeeperWatcher zkw,
int replicaId) |
List<ServerName> |
RegionServerTracker.getOnlineServers()
Gets the online servers.
|
Modifier and Type | Method and Description |
---|---|
static void |
ZKAssign.asyncCreateNodeOffline(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName serverName,
AsyncCallback.StringCallback cb,
Object ctx)
Creates an unassigned node in the OFFLINE state for the specified region.
|
static int |
ZKAssign.confirmNodeOpening(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName serverName,
int expectedVersion)
Confirm an existing unassigned node for the specified region which is
currently in the OPENING state to be still in the OPENING state on
the specified server.
|
static int |
ZKAssign.createNodeClosing(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName serverName)
Creates a new unassigned node in the CLOSING state for the specified
region.
|
static void |
ZKAssign.createNodeOffline(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName serverName)
Creates a new unassigned node in the OFFLINE state for the specified region.
|
static void |
ZKAssign.createNodeOffline(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName serverName,
EventType event) |
static int |
ZKAssign.createOrForceNodeOffline(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName serverName)
Creates or force updates an unassigned node to the OFFLINE state for the
specified region.
|
static boolean |
ZKAssign.deleteClosedNode(ZooKeeperWatcher zkw,
String encodedRegionName,
ServerName sn)
Deletes an existing unassigned node that is in the CLOSED state for the
specified region.
|
static boolean |
ZKAssign.deleteClosingNode(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName sn)
Deletes an existing unassigned node that is in the CLOSING state for the
specified region.
|
static boolean |
ZKAssign.deleteNode(ZooKeeperWatcher zkw,
String encodedRegionName,
EventType expectedState,
ServerName sn)
Deletes an existing unassigned node that is in the specified state for the
specified region.
|
static boolean |
ZKAssign.deleteNode(ZooKeeperWatcher zkw,
String encodedRegionName,
EventType expectedState,
ServerName serverName,
int expectedVersion)
Deletes an existing unassigned node that is in the specified state for the
specified region.
|
static boolean |
ZKAssign.deleteOfflineNode(ZooKeeperWatcher zkw,
String encodedRegionName,
ServerName sn)
Deletes an existing unassigned node that is in the OFFLINE state for the
specified region.
|
static boolean |
ZKAssign.deleteOpenedNode(ZooKeeperWatcher zkw,
String encodedRegionName,
ServerName sn)
Deletes an existing unassigned node that is in the OPENED state for the
specified region.
|
int |
MasterAddressTracker.getBackupMasterInfoPort(ServerName sn)
Get the info port of the backup master if it is available.
|
HBaseProtos.RegionServerInfo |
RegionServerTracker.getRegionServerInfo(ServerName sn) |
static boolean |
MasterAddressTracker.setMasterAddress(ZooKeeperWatcher zkw,
String znode,
ServerName master,
int infoPort)
Set master address into the
master znode or into the backup
subdirectory of backup masters; switch off the passed in znode
path. |
static void |
MetaTableLocator.setMetaLocation(ZooKeeperWatcher zookeeper,
ServerName serverName,
int replicaId,
RegionState.State state)
Sets the location of
hbase:meta in ZooKeeper to the
specified server address. |
static void |
MetaTableLocator.setMetaLocation(ZooKeeperWatcher zookeeper,
ServerName serverName,
RegionState.State state)
Sets the location of
hbase:meta in ZooKeeper to the
specified server address. |
static int |
ZKAssign.transitionNode(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName serverName,
EventType beginState,
EventType endState,
int expectedVersion)
Method that actually performs unassigned node transitions.
|
static int |
ZKAssign.transitionNode(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName serverName,
EventType beginState,
EventType endState,
int expectedVersion,
byte[] payload) |
static int |
ZKAssign.transitionNodeClosed(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName serverName,
int expectedVersion)
Transitions an existing unassigned node for the specified region which is
currently in the CLOSING state to be in the CLOSED state.
|
static int |
ZKAssign.transitionNodeOpened(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName serverName,
int expectedVersion)
Transitions an existing unassigned node for the specified region which is
currently in the OPENING state to be in the OPENED state.
|
static int |
ZKAssign.transitionNodeOpening(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName serverName)
Transitions an existing unassigned node for the specified region which is
currently in the OFFLINE state to be in the OPENING state.
|
static int |
ZKAssign.transitionNodeOpening(ZooKeeperWatcher zkw,
HRegionInfo region,
ServerName serverName,
EventType beginState) |