Class CosmosClient

java.lang.Object
com.azure.cosmos.CosmosClient
All Implemented Interfaces:
Closeable, AutoCloseable

public final class CosmosClient extends Object implements Closeable
Provides a client-side logical representation of the Azure Cosmos DB service. Calls to CosmosClient API's are blocked for completion.

CosmosClient is thread-safe. It's recommended to maintain a single instance of CosmosClient per lifetime of the application which enables efficient connection management and performance. CosmosClient initialization is a heavy operation - don't use initialization CosmosClient instances as credentials or network connectivity validations.