Frequently asked questions on Azure Cosmos DB for MongoDB in RU architecture

APPLIES TO: MongoDB

Does Azure Cosmos DB for MongoDB (RU) support my data residency requirements?

Yes, data residency is governed at the database account level, which is associated with one or more regions. Typically, you create a database account for each residency requirement.

Does Azure Cosmos DB for MongoDB (RU) support documents larger than 2 MB?

Yes, documents as large as 16 MB are fully supported.

Does Azure Cosmos DB for MongoDB (RU) support multi-field sort?

Yes, multi-field sort is supported. A compound index is required for the fields in the sort to ensure the operation is efficient and scalable.

Does Azure Cosmos DB for MongoDB (RU) scale linearly?

In many cases, Azure Cosmos DB's costs scale better than linear. For example, if you read a 1-KB document, this operation equates to one Request Unit (RU). But if you read a 10-KB document, this larger operation still equates to roughly one RU. The capacity calculator can help you estimate your throughput needs.

How can I encrypt Azure Cosmos DB for MongoDB (RU) data and manage access at the field level?

Azure Cosmos DB for MongoDB (RU) supports Field Level Encryption.

How do I pay for Azure Cosmos DB for MongoDB (RU) Request Units (RUs)?

Azure Cosmos DB for MongoDB (RU) offers three capacity modes: provisioned throughput, autoscale, and serverless. Autoscale instantaneously scales to meet your needs, and serverless only charges for the throughput you use.

Which features are supported in Azure Cosmos DB for MongoDB (RU)?

Azure Cosmos DB for MongoDB (RU) supports a rich set of MongoDB features backed by Azure Cosmos DB's limitless scale architecture. These features include: Aggregation pipelines, Change streams, Indexes, Geospatial queries, and more. For more information, see feature support matrix.

Does Azure Cosmos DB for MongoDB (RU) run on-premises?

Azure Cosmos DB for MongoDB (RU) is a cloud-native multitenant service and isn't available on-premises. Azure Cosmos DB offers an emulator for local development and testing.

How do I connect to my Azure Cosmos DB for MongoDB (RU) database?

The quickest way to connect to an Azure Cosmos DB for MongoDB (RU) database is to use the Quick Start feature within the resource's page in the Azure portal. The Quick Start includes code snippets preconfigured to connect to your database.

Azure Cosmos DB enforces strict security requirements and standards. Azure Cosmos DB accounts require authentication and secure communication via transport layer security (TLS/SSL). In any examples you build, use TLS/SSL version 1.2.

For more information, see Connect to your API for MongoDB RU database.

What do the error codes mean while using Azure Cosmos DB for MongoDB (RU)?

Along with the common MongoDB error codes, Azure Cosmos DB for MongoDB (RU) has its own specific error codes. For more information, see API for MongoDB (RU) troubleshooting guide.

Are non-Microsoft drivers for MongoDB supported for use with Azure Cosmos DB for MongoDB (RU)?

Yes, you can use non-Microsoft MongoDB Open Database Connectivity (ODBC) drivers with Azure Cosmos DB for MongoDB (RU).