Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ConnectionPolicy

Represents the Connection policy associated with a CosmosClient in the Azure Cosmos DB database service.

Hierarchy

  • ConnectionPolicy

Index

Properties

ConnectionMode

ConnectionMode: Gateway = ConnectionMode.Gateway

Determines which mode to connect to Cosmos with. (Currently only supports Gateway option)

DisableSSLVerification

DisableSSLVerification: boolean = false

Flag to disable SSL verification for the requests. SSL verification is enabled by default. Don't set this when targeting production endpoints. This is intended to be used only when targeting emulator endpoint to avoid failing your requests with SSL related error.

EnableEndpointDiscovery

EnableEndpointDiscovery: boolean = true

Flag to enable/disable automatic redirecting of requests based on read/write operations.

MediaReadMode

MediaReadMode: keyof MediaReadMode = MediaReadMode.Buffered

Attachment content (aka media) download mode. Should be one of the values of MediaReadMode

MediaRequestTimeout

MediaRequestTimeout: number = ConnectionPolicy.defaultMediaRequestTimeout

Time to wait for response from network peer for attachment content (aka media) operations. Represented in milliseconds.

PreferredLocations

PreferredLocations: string[] = []

List of azure regions to be used as preferred locations for read requests.

ProxyUrl

ProxyUrl: string = ""

Http/Https proxy url

RequestTimeout

RequestTimeout: number = ConnectionPolicy.defaultRequestTimeout

Request timeout (time to wait for response from network peer). Represented in milliseconds.

RetryOptions

RetryOptions: RetryOptions = new RetryOptions()

RetryOptions instance which defines several configurable properties used during retry.

UseMultipleWriteLocations

UseMultipleWriteLocations: boolean = false

The flag that enables writes on any locations (regions) for geo-replicated database accounts in the Azure Cosmos DB service. Default is false.

Generated using TypeDoc