Client Builder Class
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
This is a Builder class that creates a cosmos client
public class CosmosClientBuilder
type CosmosClientBuilder = class
Public Class CosmosClientBuilder
Extracts the account endpoint and key from the connection string.
Initialize a new CosmosConfiguration class that holds all the properties the CosmosClient requires.
A method to create the cosmos client
A suffix to be added to the default user-agent for the Azure Cosmos DB service.
Set the preferred geo-replicated region to be used in the Azure Cosmos DB service.
Sets the connection mode to Direct. This is used by the client when connecting to the Azure Cosmos DB service.
Sets the connection mode to Gateway. This is used by the client when connecting to the Azure Cosmos DB service.
This can be used to weaken the database account consistency level for read operations. If this is not set the database account consistency level will be used for all requests.
Set a custom JSON serializer.
Limits the operations to the provided endpoint on the CosmosClientBuilder constructor.
Sets the request timeout in seconds when connecting to the Azure Cosmos DB service.
Set a custom serializer option.
Sets the minimum time to wait between retry and the max number of times to retry on throttled requests.