Azure Cosmos DB is a distributed, multimodal database. It was built from the ground up with distribution and horizontal scaling at its core. It offers turnkey distribution across any number of Azure regions by transparently scaling and replicating data (wherever users are). Flexibly scale throughput and storage within the range of multiple data centers, and only pay for what you need. Azure Cosmos DB guarantees single digit millisecond latencies at the 99th percentile, offers multiple well-defined consistency models for fine tuning performance, and guarantees high availability with multi-homing functionality anywhere in each region – all supported by industry-leading, comprehensive Service Level Agreements (SLAs).
Azure Cosmos DB really is architecture-independent. It can automatically index all data without having to deal with architecture and index management. It is also a data model with multiple models, local support documentation, key values, graphs, and columns. With Azure Cosmos DB, you can use selected APIs to access data because DocumentDB SQL (documents) and MongoDB (documents) and Azure Table Storage (key-value), Gremlin (graph), and Cassandra (column-family) are all supported locally.
|AZURE COSMOS DB CAPABILITIES|
|Turnkey global distribution with multi-master capability|
|Global Availability (all Azure regions, including US Government, DoD, China)|
|Multi-model, multi-API with rich query support and automatic indexing|
|Single digit millisecond read and write latency at the 99th percentile backed by SLA|
Elastic and Limitless Scale
|Comprehensive compliance certifications consistent with Azure compliance|
Pricing at a glance
Your Azure Cosmos DB database account could be distributed across one or more Azure regions. While all the regions associated with your database account can serve reads, your database account can also be configured to have all regions to process the writes (multi-master) or exactly one region to process the writes (single-master).
In Azure Cosmos DB, you are billed for the provisioned throughput and consumed storage by the hour. The throughput is expressed in terms of a normalized throughput currency called Request Units per second (RU/s). Once provisioned, RU/s can be used interchangeably across various database operations (e.g., inserts, reads, replaces, upserts, deletes, queries, etc.). You can programmatically (or via Azure Portal) configure the throughput you need and elastically scale the provisioned throughput at any time.
Provisioning at different granularities
You can provision throughput at different granularities You can provision throughput for:
- Cosmos DB container. Depending on the choice of data model or API, a Cosmos DB container can be a collection (e.g., MongoDB, SQL), a graph (e.g., Gremlin), or a table (e.g., Cassandra, Azure Table storage). Containers in Cosmos DB are horizontally partitioned and can elastically scale to deliver unlimited amount of throughput and storage.
- Cosmos DB database. The throughput configured on the database is shared across all the containers of the database. You can choose to explicitly exclude certain containers from database provisioning and instead provision throughput for those containers at container level.
|GRANULARITY OF PROVISIONING||MINIMUM THROUGHPUT (RU/S)||SCALE UP/DOWN INCREMENTS (RU/S)||MAXIMUM THROUGHPUT||SCOPE|
|SINGLE REGION WRITE||MULTIPLE REGION WRITE||SINGLE REGION WRITE||MULTIPLE REGION WRITE|
|Container*||400||400||100||100||Unlimited||The partitioned container for which the throughput is provisioned|
|Database**||400||400||100||100||Unlimited||All the throughput is shared among all the partitioned-containers within the database (excluding the containers for which the throughput is explicitly provisioned for)|
Elastically scaling reads and writes across the globe
You can add/remove Azure regions anywhere in the world to your Cosmos DB database account at any time. The throughput that you have configured for various Cosmos DB databases and containers is guaranteed to be reserved in each of the Azure regions associated with your Cosmos DB database account.
Your data and index are durably stored on the SSD-backed storage and replicated (across one or more Azure regions associated with your Cosmos DB database account). In addition to the throughput that you provision every hour, you are also billed for each GB of storage that you actually consume for your data and index.
|SSD Storage (per GB)||¥2.576/GB/month|
|Provisioned Throughput (single region writes) per 100 RU/s||¥0.082/hour (about ¥61.01/month)|
|Provisioned Throughput (multiple region writes) per 100 RU/s||¥0.102/hour (about ¥75.888/month)|
For high-throughput and high-storage workloads, you can create unlimited containers by defining a partition key when a collection is created. A partitioned container will seamlessly scale out as the quantity of stored data grows and provisioned throughput increases.
Multi-regional scale with geo-replication
Azure Cosmos DB containers can be distributed, which means all your data can be automatically replicated to the regions you specify. Your app continues to work using a logical endpoint, while your data is automatically extracted and served to users from their nearest region using an intuitive programming model for data consistency and 99.99% availability. Distributed containers are billed based on the storage consumed in each region and the throughput provisioned for each Azure Cosmos DB container multiplied by the number of regions associated with an Azure Cosmos DB database account. Standard data transfer rates apply for replication data transfer between regions. For example, suppose a user has a database account that spans three Azure regions and two containers that are provisioned with 1 million RUs and 2 million RUs respectively. The total provisioned RUs for the first container will be 3 million RUs (1 million RUs x 3 regions), and the total provisioned RUs for the second container will be 6 million RUs (2 million RUs x 3 regions).
High throughput and low-latency queries
When writing a sustained amount of data with Azure Cosmos DB, the data is indexed synchronously to provide consistent SQL queries using a write-optimized, latch-free database engine designed for solid-state drives (SSDs) and low-latency access. When data is distributed, read and write requests always originate from the local region. Performance can be further optimized by customizing automatic index behavior.
What is a request unit?
A request unit (RU) is the unit of measurement for throughput in Azure Cosmos DB. 1 RU corresponds to the throughput for obtaining a 1 KB file. Every operation performed in DocumentDB (including reads, writes, SQL queries, and stored procedure executions) has a determined request unit value based on the throughput required to complete the operation. Instead of thinking about CPU, IO, and memory, and how they affect your application throughput, you can think in terms of a single Request Unit measure.
A request unit used through provisioned RUs per second or a one-minute bucket is the same.
For details on request units and help determining your collection needs, please see Request Units in Azure Cosmos DB.
How does request unit usage appear on my bill?
During this period, billing is based on the total capacity (RU/second) provisioned under your Azure Cosmos DB account, using predictable hourly rates that fluctuate steadily.
If you create accounts for two partitions that use 500 RU/second and 700 RU/second respectively, the total provisioned capacity will reach 1,200 RU/second. Therefore, the billing amount will be 12 x ¥0.082 = ¥0.984/hour.
If your throughput needs to be changed and you increase the capacity of each partition by 500 RU/second, while also creating a new unlimited container using 20,000 RU/s, your overall provisioned capacity would be 22,200 RU/second (1,000 RU/second + 1,200 RU/second + 20,000 RU/second). Your bill would then change to: ¥0.082 x 222 = ¥18.204/hour.
In a month of 720 hours, if 500 hours are provisioned at 1,200 RU/second and 220 hours are provisioned at 22,200 RU/second, the monthly bill will show: 500 x ¥0.984/hour + 220 x ¥18.204/hour = ¥4,496.88.
Working principles of request units per minute
In addition to the normal preview throughput, additional per minute request units can now be provisioned. You can use these additional throughput units in the UTC minute window. If per minute request units are enabled, an additional 1,000 request units per minute can be used for every 100 RU/second provisioned in a container.
For example, if you provision 400 RU/second, you can use an additional 4,000 request units per second. Suppose that an application requires more than 400 RU/second at 12 o'clock noon. From 12:00:01 p.m. to 12:01:00 p.m., the application will be able to use 4,000 additional request units while continuing to use the provisioned 400 RU/second throughput. Starting from 12:00:01 p.m., if all 4,000 request units are used before 12:01:00 p.m., the other request units cannot be used until the next UTC minute (starting from 12:01:01 p.m.). If you do not use all 4,000 request units within a given minute time interval, the remaining request units will not accumulate to the next minute time interval.
Please see Number of per minute request units in Azure Cosmos DB for details.
If I specify my own performance for the container, how will the storage be billed?
Storage capacity is billed according to the maximum hourly amount of data stored (in GB) over a monthly period. For example, if you used 100 GB of storage in the first half of the month and 50 GB in the second half of the month, you would be billed for an equivalent of 75 GB of storage during that month.
How will I be billed if my container is active for less than an hour?
You are billed the flat rate for each hour the container exists, regardless of usage or if the collection is active for less than an hour. For example, if you create a container and delete it five minutes later, your bill will reflect a charge of one unit hour.
How do I increase or decrease the throughput for each collection?
You can increase or decrease the number of request units per container in an Azure Cosmos DB account using one of the supported SDKs or REST APIs in the Azure portal.
Support & SLA
If you have any questions or need help, please visit Azure Support to select self-service or any other methods to contact us for support.
Azure Cosmos DB operated by 21Vianet in China is a distributed multi-model database service. It provides turnkey data distribution in different Azure Data Centers in China, so your users can adjust and replicate your data transparently, no matter where they are located. This service offers a comprehensive 99.99% Service Level Agreement that includes a Cosmos DB database account for a single Azure region configured with any of five levels of consistency, or throughput, consistency, availability, and latency guarantees for database accounts across multiple Azure regions configured with any of four levels of loose consistency. In addition to consistency level selection, Cosmos DB also offers a 99.999% Service Level Agreement for database accounts with read availability across two or more Azure regions.
To learn more about the details of our Service Level Agreement, please visit the Service Level Agreement page.