Package org.apache.hadoop.hbase.client
Class AsyncNonMetaRegionLocator
java.lang.Object
org.apache.hadoop.hbase.client.AsyncNonMetaRegionLocator
The asynchronous locator for regions other than meta.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static final classprivate static final classprivate static final class -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ConcurrentMap<TableName,AsyncNonMetaRegionLocator.TableCache> private final AsyncConnectionImplprivate static final intprivate static final int(package private) static Stringprivate final intprivate static final org.slf4j.Logger(package private) static final Stringprivate final intprivate CatalogReplicaModeprivate final org.apache.hbase.thirdparty.io.netty.util.HashedWheelTimer -
Constructor Summary
ConstructorsConstructorDescriptionAsyncNonMetaRegionLocator(AsyncConnectionImpl conn, org.apache.hbase.thirdparty.io.netty.util.HashedWheelTimer retryTimer) -
Method Summary
Modifier and TypeMethodDescription(package private) void(package private) void(package private) voidclearCache(ServerName serverName) (package private) voidclearCache(TableName tableName) private voidcomplete(TableName tableName, AsyncNonMetaRegionLocator.LocateRequest req, RegionLocations locs, Throwable error) private HRegionLocation(package private) RegionLocationsgetCachedLocation(TableName tableName, byte[] startKey) private org.apache.hbase.thirdparty.io.netty.util.TimerTaskgetInvalidateMetaCacheTask(long metaCacheInvalidateInterval) (package private) intgetNumberOfCachedRegionLocations(TableName tableName) (package private) RegionLocationsgetRegionLocationInCache(TableName tableName, byte[] row) (package private) CompletableFuture<RegionLocations>getRegionLocations(TableName tableName, byte[] row, int replicaId, RegionLocateType locateType, boolean reload) private CompletableFuture<RegionLocations>getRegionLocationsInternal(TableName tableName, byte[] row, int replicaId, RegionLocateType locateType, boolean reload) getTableCache(TableName tableName) private voidinvalidateCache(CompletableFuture<Void> future, Iterator<TableName> tbnIter, AsyncAdmin admin) private CompletableFuture<Void>private RegionLocationslocateInCache(AsyncNonMetaRegionLocator.TableCache tableCache, byte[] row, int replicaId, RegionLocateType locateType) private voidlocateInMeta(TableName tableName, AsyncNonMetaRegionLocator.LocateRequest req) private RegionLocationslocateRowBeforeInCache(AsyncNonMetaRegionLocator.TableCache tableCache, byte[] row, int replicaId) private RegionLocationslocateRowInCache(AsyncNonMetaRegionLocator.TableCache tableCache, byte[] row, int replicaId) private booleanonScanNext(TableName tableName, AsyncNonMetaRegionLocator.LocateRequest req, Result result) private voidprivate voidprivate voidprivate void(package private) voidupdateCachedLocationOnError(HRegionLocation loc, Throwable exception) private void
-
Field Details
-
LOG
-
MAX_CONCURRENT_LOCATE_REQUEST_PER_TABLE
- See Also:
-
DEFAULT_MAX_CONCURRENT_LOCATE_REQUEST_PER_TABLE
- See Also:
-
LOCATE_PREFETCH_LIMIT
-
DEFAULT_LOCATE_PREFETCH_LIMIT
- See Also:
-
conn
-
maxConcurrentLocateRequestPerTable
-
locatePrefetchLimit
-
metaReplicaMode
-
metaReplicaSelector
-
cache
-
retryTimer
-
-
Constructor Details
-
AsyncNonMetaRegionLocator
AsyncNonMetaRegionLocator(AsyncConnectionImpl conn, org.apache.hbase.thirdparty.io.netty.util.HashedWheelTimer retryTimer)
-
-
Method Details
-
getTableCache
-
complete
private void complete(TableName tableName, AsyncNonMetaRegionLocator.LocateRequest req, RegionLocations locs, Throwable error) -
onScanNext
private boolean onScanNext(TableName tableName, AsyncNonMetaRegionLocator.LocateRequest req, Result result) -
recordCacheHit
-
recordCacheMiss
-
locateRowInCache
private RegionLocations locateRowInCache(AsyncNonMetaRegionLocator.TableCache tableCache, byte[] row, int replicaId) -
locateRowBeforeInCache
private RegionLocations locateRowBeforeInCache(AsyncNonMetaRegionLocator.TableCache tableCache, byte[] row, int replicaId) -
locateInMeta
-
locateInCache
private RegionLocations locateInCache(AsyncNonMetaRegionLocator.TableCache tableCache, byte[] row, int replicaId, RegionLocateType locateType) -
getRegionLocationsInternal
private CompletableFuture<RegionLocations> getRegionLocationsInternal(TableName tableName, byte[] row, int replicaId, RegionLocateType locateType, boolean reload) -
getRegionLocations
CompletableFuture<RegionLocations> getRegionLocations(TableName tableName, byte[] row, int replicaId, RegionLocateType locateType, boolean reload) -
recordClearRegionCache
-
removeLocationFromCache
-
updateMetaReplicaSelector
-
addLocationToCache
-
getCachedLocation
-
getCachedLocation
-
updateCachedLocationOnError
-
clearCache
-
clearCache
void clearCache() -
clearCache
-
getRegionLocationInCache
-
getNumberOfCachedRegionLocations
-
getInvalidateMetaCacheTask
private org.apache.hbase.thirdparty.io.netty.util.TimerTask getInvalidateMetaCacheTask(long metaCacheInvalidateInterval) -
invalidateTableCache
-
invalidateCache
private void invalidateCache(CompletableFuture<Void> future, Iterator<TableName> tbnIter, AsyncAdmin admin)
-