@InterfaceAudience.Private public interface ClusterConnection extends Connection
Modifier and Type | Field and Description |
---|---|
static String |
HBASE_CLIENT_CONNECTION_IMPL
Key for configuration in Configuration whose value is the class we implement making a
new Connection instance.
|
Modifier and Type | Method and Description |
---|---|
void |
cacheLocation(TableName tableName,
RegionLocations location) |
void |
clearCaches(ServerName sn)
Clear any caches that pertain to server name
sn . |
default void |
clearRegionCache()
Deprecated.
|
void |
clearRegionCache(TableName tableName)
Allows flushing the region cache of all locations that pertain to
tableName |
void |
deleteCachedRegionLocation(HRegionLocation location)
Deletes cached locations for the specific region.
|
org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.AdminService.BlockingInterface |
getAdmin(ServerName serverName)
Establishes a connection to the region server at the specified address.
|
org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.AdminService.BlockingInterface |
getAdminForMaster()
Get the admin service for master.
|
AsyncProcess |
getAsyncProcess() |
ClientBackoffPolicy |
getBackoffPolicy() |
org.apache.hadoop.hbase.shaded.protobuf.generated.ClientProtos.ClientService.BlockingInterface |
getClient(ServerName serverName)
Establishes a connection to the region server at the specified address, and returns
a region client protocol.
|
ConnectionConfiguration |
getConnectionConfiguration() |
MetricsConnection |
getConnectionMetrics() |
MasterKeepAliveConnection |
getMaster()
Returns a
MasterKeepAliveConnection to the active master |
RpcRetryingCallerFactory |
getNewRpcRetryingCallerFactory(org.apache.hadoop.conf.Configuration conf)
Returns a new RpcRetryingCallerFactory from the given
Configuration . |
NonceGenerator |
getNonceGenerator() |
HRegionLocation |
getRegionLocation(TableName tableName,
byte[] row,
boolean reload)
Find region location hosting passed row
|
RpcControllerFactory |
getRpcControllerFactory() |
RpcRetryingCallerFactory |
getRpcRetryingCallerFactory() |
ServerStatisticTracker |
getStatisticsTracker() |
TableState |
getTableState(TableName tableName)
Retrieve TableState, represent current table state.
|
boolean |
hasCellBlockSupport() |
boolean |
isMasterRunning()
Deprecated.
this has been deprecated without a replacement
|
boolean |
isTableAvailable(TableName tableName,
byte[][] splitKeys)
Use this api to check if the table has been created with the specified number of
splitkeys which was used while creating the given table.
|
boolean |
isTableDisabled(TableName tableName) |
boolean |
isTableEnabled(TableName tableName)
A table that isTableEnabled == false and isTableDisabled == false
is possible.
|
HRegionLocation |
locateRegion(byte[] regionName)
Gets the location of the region of regionName.
|
HRegionLocation |
locateRegion(TableName tableName,
byte[] row)
Find the location of the region of tableName that row
lives in.
|
RegionLocations |
locateRegion(TableName tableName,
byte[] row,
boolean useCache,
boolean retry) |
RegionLocations |
locateRegion(TableName tableName,
byte[] row,
boolean useCache,
boolean retry,
int replicaId) |
List<HRegionLocation> |
locateRegions(TableName tableName)
Gets the locations of all regions in the specified table, tableName.
|
List<HRegionLocation> |
locateRegions(TableName tableName,
boolean useCache,
boolean offlined)
Gets the locations of all regions in the specified table, tableName.
|
HRegionLocation |
relocateRegion(TableName tableName,
byte[] row)
Find the location of the region of tableName that row
lives in, ignoring any value that might be in the cache.
|
RegionLocations |
relocateRegion(TableName tableName,
byte[] row,
int replicaId)
Find the location of the region of tableName that row
lives in, ignoring any value that might be in the cache.
|
void |
updateCachedLocations(TableName tableName,
byte[] regionName,
byte[] rowkey,
Object exception,
ServerName source)
Update the location cache.
|
clearRegionLocationCache, close, getAdmin, getBufferedMutator, getBufferedMutator, getConfiguration, getHbck, getHbck, getRegionLocator, getTable, getTable, getTableBuilder, isClosed
static final String HBASE_CLIENT_CONNECTION_IMPL
@Deprecated boolean isMasterRunning() throws MasterNotRunningException, ZooKeeperConnectionException
MasterNotRunningException
ZooKeeperConnectionException
boolean isTableAvailable(TableName tableName, byte[][] splitKeys) throws IOException
tableName
- tableNamesplitKeys
- splitKeys used while creating tableIOException
- if a remote or network exception occursboolean isTableEnabled(TableName tableName) throws IOException
tableName
- table nameIOException
- if a remote or network exception occursboolean isTableDisabled(TableName tableName) throws IOException
tableName
- table nameIOException
- if a remote or network exception occursTableState getTableState(TableName tableName) throws IOException
tableName
- table state forIOException
HRegionLocation locateRegion(TableName tableName, byte[] row) throws IOException
tableName
- name of the table row is inrow
- row key you're trying to find the region ofIOException
- if a remote or network exception occurs@Deprecated default void clearRegionCache()
Connection.clearRegionLocationCache()
instead.void cacheLocation(TableName tableName, RegionLocations location)
void clearRegionCache(TableName tableName)
tableName
tableName
- Name of the table whose regions we are to remove from
cache.void deleteCachedRegionLocation(HRegionLocation location)
location
- The location object for the region, to be purged from cache.HRegionLocation relocateRegion(TableName tableName, byte[] row) throws IOException
tableName
- name of the table row is inrow
- row key you're trying to find the region ofIOException
- if a remote or network exception occursRegionLocations relocateRegion(TableName tableName, byte[] row, int replicaId) throws IOException
tableName
- name of the table row is inrow
- row key you're trying to find the region ofreplicaId
- the replicaId of the regionIOException
- if a remote or network exception occursvoid updateCachedLocations(TableName tableName, byte[] regionName, byte[] rowkey, Object exception, ServerName source)
tableName
- the table nameregionName
- the region namerowkey
- the rowexception
- the exception if any. Can be null.source
- the previous locationHRegionLocation locateRegion(byte[] regionName) throws IOException
regionName
- name of the region to locateIOException
- if a remote or network exception occursList<HRegionLocation> locateRegions(TableName tableName) throws IOException
tableName
- table to get regions ofIOException
- if IO failure occursList<HRegionLocation> locateRegions(TableName tableName, boolean useCache, boolean offlined) throws IOException
tableName
- table to get regions ofuseCache
- Should we use the cache to retrieve the region information.offlined
- True if we are to include offlined regions, false and we'll leave out offlined
regions from returned list.IOException
- if IO failure occursRegionLocations locateRegion(TableName tableName, byte[] row, boolean useCache, boolean retry) throws IOException
tableName
- table to get regions ofrow
- the rowuseCache
- Should we use the cache to retrieve the region information.retry
- do we retryIOException
- if IO failure occursRegionLocations locateRegion(TableName tableName, byte[] row, boolean useCache, boolean retry, int replicaId) throws IOException
tableName
- table to get regions ofrow
- the rowuseCache
- Should we use the cache to retrieve the region information.retry
- do we retryreplicaId
- the replicaId for the regionIOException
- if IO failure occursMasterKeepAliveConnection getMaster() throws IOException
MasterKeepAliveConnection
to the active masterIOException
org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.AdminService.BlockingInterface getAdminForMaster() throws IOException
IOException
org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.AdminService.BlockingInterface getAdmin(ServerName serverName) throws IOException
serverName
- the region server to connect toIOException
- if a remote or network exception occursorg.apache.hadoop.hbase.shaded.protobuf.generated.ClientProtos.ClientService.BlockingInterface getClient(ServerName serverName) throws IOException
serverName
- the region server to connect toIOException
- if a remote or network exception occursHRegionLocation getRegionLocation(TableName tableName, byte[] row, boolean reload) throws IOException
tableName
- table namerow
- Row to find.reload
- If true do not use cache, otherwise bypass.IOException
- if a remote or network exception occursvoid clearCaches(ServerName sn)
sn
.sn
- A server nameNonceGenerator getNonceGenerator()
AsyncProcess getAsyncProcess()
RpcRetryingCallerFactory getNewRpcRetryingCallerFactory(org.apache.hadoop.conf.Configuration conf)
Configuration
.
This RpcRetryingCallerFactory lets the users create RpcRetryingCaller
s which can be
intercepted with the configured RetryingCallerInterceptor
conf
- configurationRpcRetryingCallerFactory getRpcRetryingCallerFactory()
RpcControllerFactory getRpcControllerFactory()
ConnectionConfiguration getConnectionConfiguration()
ServerStatisticTracker getStatisticsTracker()
ClientBackoffPolicy getBackoffPolicy()
MetricsConnection getConnectionMetrics()
boolean hasCellBlockSupport()
Codec
and so
supports cell blocks.Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.