private static final class AsyncNonMetaRegionLocator.TableCache extends Object
Modifier and Type | Field and Description |
---|---|
private Map<AsyncNonMetaRegionLocator.LocateRequest,CompletableFuture<RegionLocations>> |
allRequests |
private ConcurrentNavigableMap<byte[],RegionLocations> |
cache |
private Set<AsyncNonMetaRegionLocator.LocateRequest> |
pendingRequests |
Modifier | Constructor and Description |
---|---|
private |
TableCache() |
Modifier and Type | Method and Description |
---|---|
List<AsyncNonMetaRegionLocator.RegionLocationsFutureResult> |
clearCompletedRequests(RegionLocations locations) |
Optional<AsyncNonMetaRegionLocator.LocateRequest> |
getCandidate() |
boolean |
hasQuota(int max) |
boolean |
isPending(AsyncNonMetaRegionLocator.LocateRequest req) |
void |
send(AsyncNonMetaRegionLocator.LocateRequest req) |
private boolean |
tryComplete(AsyncNonMetaRegionLocator.LocateRequest req,
CompletableFuture<RegionLocations> future,
RegionLocations locations,
List<AsyncNonMetaRegionLocator.RegionLocationsFutureResult> futureResultList) |
private final ConcurrentNavigableMap<byte[],RegionLocations> cache
private final Set<AsyncNonMetaRegionLocator.LocateRequest> pendingRequests
private final Map<AsyncNonMetaRegionLocator.LocateRequest,CompletableFuture<RegionLocations>> allRequests
private TableCache()
public boolean hasQuota(int max)
public boolean isPending(AsyncNonMetaRegionLocator.LocateRequest req)
public void send(AsyncNonMetaRegionLocator.LocateRequest req)
public Optional<AsyncNonMetaRegionLocator.LocateRequest> getCandidate()
public List<AsyncNonMetaRegionLocator.RegionLocationsFutureResult> clearCompletedRequests(RegionLocations locations)
private boolean tryComplete(AsyncNonMetaRegionLocator.LocateRequest req, CompletableFuture<RegionLocations> future, RegionLocations locations, List<AsyncNonMetaRegionLocator.RegionLocationsFutureResult> futureResultList)
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.