public class GatewayAddressCache extends Object implements IAddressCache
| Constructor and Description |
|---|
GatewayAddressCache(URL serviceEndpoint,
com.microsoft.azure.cosmosdb.internal.directconnectivity.Protocol protocol,
com.microsoft.azure.cosmosdb.rx.internal.IAuthorizationTokenProvider tokenProvider,
com.microsoft.azure.cosmosdb.internal.UserAgentContainer userAgent,
io.reactivex.netty.protocol.http.client.CompositeHttpClient<io.netty.buffer.ByteBuf,io.netty.buffer.ByteBuf> httpClient) |
GatewayAddressCache(URL serviceEndpoint,
com.microsoft.azure.cosmosdb.internal.directconnectivity.Protocol protocol,
com.microsoft.azure.cosmosdb.rx.internal.IAuthorizationTokenProvider tokenProvider,
com.microsoft.azure.cosmosdb.internal.UserAgentContainer userAgent,
io.reactivex.netty.protocol.http.client.CompositeHttpClient<io.netty.buffer.ByteBuf,io.netty.buffer.ByteBuf> httpClient,
long suboptimalPartitionForceRefreshIntervalInSeconds) |
| Modifier and Type | Method and Description |
|---|---|
void |
dispose() |
rx.Completable |
openAsync(DocumentCollection collection,
List<com.microsoft.azure.cosmosdb.internal.routing.PartitionKeyRangeIdentity> partitionKeyRangeIdentities) |
rx.Single<com.microsoft.azure.cosmosdb.internal.directconnectivity.AddressInformation[]> |
tryGetAddresses(com.microsoft.azure.cosmosdb.rx.internal.RxDocumentServiceRequest request,
com.microsoft.azure.cosmosdb.internal.routing.PartitionKeyRangeIdentity partitionKeyRangeIdentity,
boolean forceRefreshPartitionAddresses)
Resolves physical addresses by either PartitionKeyRangeIdentity.
|
public GatewayAddressCache(URL serviceEndpoint, com.microsoft.azure.cosmosdb.internal.directconnectivity.Protocol protocol, com.microsoft.azure.cosmosdb.rx.internal.IAuthorizationTokenProvider tokenProvider, com.microsoft.azure.cosmosdb.internal.UserAgentContainer userAgent, io.reactivex.netty.protocol.http.client.CompositeHttpClient<io.netty.buffer.ByteBuf,io.netty.buffer.ByteBuf> httpClient, long suboptimalPartitionForceRefreshIntervalInSeconds)
public GatewayAddressCache(URL serviceEndpoint, com.microsoft.azure.cosmosdb.internal.directconnectivity.Protocol protocol, com.microsoft.azure.cosmosdb.rx.internal.IAuthorizationTokenProvider tokenProvider, com.microsoft.azure.cosmosdb.internal.UserAgentContainer userAgent, io.reactivex.netty.protocol.http.client.CompositeHttpClient<io.netty.buffer.ByteBuf,io.netty.buffer.ByteBuf> httpClient)
public rx.Single<com.microsoft.azure.cosmosdb.internal.directconnectivity.AddressInformation[]> tryGetAddresses(com.microsoft.azure.cosmosdb.rx.internal.RxDocumentServiceRequest request, com.microsoft.azure.cosmosdb.internal.routing.PartitionKeyRangeIdentity partitionKeyRangeIdentity, boolean forceRefreshPartitionAddresses)
IAddressCachetryGetAddresses in interface IAddressCacherequest - Request is needed only by GatewayAddressCache in the only case when request is name based and user has name based auth token.
PartitionkeyRangeIdentity can be used to locate auth token in this case.partitionKeyRangeIdentity - target partition key range IdforceRefreshPartitionAddresses - Whether addresses need to be refreshed as previously resolved addresses were determined to be outdated.public void dispose()
public rx.Completable openAsync(DocumentCollection collection, List<com.microsoft.azure.cosmosdb.internal.routing.PartitionKeyRangeIdentity> partitionKeyRangeIdentities)
Copyright © 2020. All rights reserved.