public class PDClient extends AbstractGRPCClient<PDGrpc.PDBlockingStub,PDGrpc.PDStub> implements ReadOnlyPDClient
asyncStub, blockingStub, channelFactory, conf, timeoutcallAsyncWithRetry, callServerStreamingWithRetry, callWithRetry, checkHealth, getConf, getTimeoutpublic static ReadOnlyPDClient create(TiConfiguration conf, ChannelFactory channelFactory)
public TiTimestamp getTimestamp(BackOffer backOffer)
ReadOnlyPDClientgetTimestamp 在接口中 ReadOnlyPDClientpublic HostMapping getHostMapping()
getHostMapping 在接口中 ReadOnlyPDClientpublic TiRegion getRegionByKey(BackOffer backOffer, com.google.protobuf.ByteString key)
ReadOnlyPDClientgetRegionByKey 在接口中 ReadOnlyPDClientkey - key in bytes for locating a regionpublic Future<TiRegion> getRegionByKeyAsync(BackOffer backOffer, com.google.protobuf.ByteString key)
getRegionByKeyAsync 在接口中 ReadOnlyPDClientpublic TiRegion getRegionByID(BackOffer backOffer, long id)
ReadOnlyPDClientgetRegionByID 在接口中 ReadOnlyPDClientid - Region Idpublic Future<TiRegion> getRegionByIDAsync(BackOffer backOffer, long id)
getRegionByIDAsync 在接口中 ReadOnlyPDClientpublic Metapb.Store getStore(BackOffer backOffer, long storeId)
ReadOnlyPDClientgetStore 在接口中 ReadOnlyPDClientstoreId - StoreIdpublic Future<Metapb.Store> getStoreAsync(BackOffer backOffer, long storeId)
getStoreAsync 在接口中 ReadOnlyPDClientpublic List<Metapb.Store> getAllStores(BackOffer backOffer)
getAllStores 在接口中 ReadOnlyPDClientpublic void close()
throws InterruptedException
close 在接口中 AutoCloseableInterruptedExceptionpublic void updateLeader()
public void updateLeaderOrForwardFollower()
public void updateTiFlashReplicaStatus()
public double getTiFlashReplicaProgress(long tableId)
protected PDGrpc.PDBlockingStub getBlockingStub()
protected PDGrpc.PDStub getAsyncStub()
Copyright © 2022 PingCAP. All rights reserved.