Language

CosmosClientBuilder.WithEnableRemoteRegionPreferredForSessionRetry Method

Definition

Provides SessionTokenMismatchRetryPolicy optimization through customer supplied region switch hints, which guide SDK-internal retry policies on how early to fallback to the next applicable region. With a single-write-region account the next applicable region is the write-region, with a multi-write-region account the next applicable region is the next region in the order of effective preferred regions (same order also used for read/query operations).

public Microsoft.Azure.Cosmos.Fluent.CosmosClientBuilder WithEnableRemoteRegionPreferredForSessionRetry(bool enableRemoteRegionPreferredForSessionRetry);
member this.WithEnableRemoteRegionPreferredForSessionRetry : bool -> Microsoft.Azure.Cosmos.Fluent.CosmosClientBuilder
Public Function WithEnableRemoteRegionPreferredForSessionRetry (enableRemoteRegionPreferredForSessionRetry As Boolean) As CosmosClientBuilder

Parameters

enableRemoteRegionPreferredForSessionRetry
Boolean

Returns

The CosmosClientBuilder object

Applies to