Last week, Microsoft announced that Azure Cosmos DB has hit general availability, which is intended to fundamentally transform the way apps are built for the cloud.
Azure Cosmos DB is the first globally-distributed data service that lets you to elastically scale throughput and storage across any number of geographical regions while guaranteeing low latency, high availability and consistency – backed by the most comprehensive SLAs in the industry. Azure Cosmos DB is built to power today’s IoT and mobile apps, and tomorrow’s AI-hungry future. — Dharma Shukla, Distinguished Engineer & General Manager, OSS Analytics and NoSQL
With Azure Cosmos DB, customers can elastically (and independently) scale throughput and storage across the many geographical regions that are supported by Microsoft. Its features make it the first and only globally distributed database service offered today to offer comprehensive SLAs that encompass the four requirements of Microsoft’s customers:
- Latency (99% percentile)
Azure Cosmos DB is the first server service that will be accepting many different data models and popular query APIs, which will support massive amounts of data without any lag or schema/index management delays.
Inspiration behind Azure Cosmos DB
Microsoft is paying homage to the expert behind the creation of Azure Cosmos DB, Dr. Leslie Lamport. Lamport is a Turing award winning Microsoft researcher. In the video below, he explains that data can be replicated and copies can be distributed globally. Thus, applications can be configured, leaving all users near the data and minimizing worry for developers who might have to worry about where the data is located.
History of Azure Cosmos DB
How did we get here? Azure Cosmos DB was code-named “Project Florence” in 2010 to help address many pain points that developers faced by large scale Microsoft applications. The team at Microsoft realized this issue isn’t restricted to their company only, so in 2015, the first generation of this technology was made available to Azure developers, known as Azure DocumentDB. With feedback from developers, the project was iterated upon heavily with new features.
Enter Azure Cosmos DB.
How Azure Cosmos DB transforms cloud-based app development
Microsoft believes that Azure Cosmos DB will certainly transform the way apps are built for the cloud. Here are the ways they see that as being possible.
- Building globally distributed apps easily: Global distribution is turnkey with Azure Cosmos DB. To add/remove any Azure region to your database replication, you just need to click. That’s it. Azure performs the rest by replicating the data seamlessly.
- Elastically scale throughput and storage anytime around the globe: Admins can elastically scale up from thousands to hundreds of millions of requests per seconds around the globe on-demand using a single API call. You pay for the throughput you need, and you can specify whether you want both second and minute granularities which helps admins deal with potential spikes without overprovisioning.
- Building highly responsive apps: As mentioned earlier, with a 99% latency, Azure Cosmos DB is guaranteeing single digit millisecond delays. The core of the Azure Cosmos DB is write-optimized, log structured, and latch-free.
- Building apps that are “always on”: Microsoft guarantees high availability of data in every region and across the world. Therefore, even in case of some sort of regional disaster, the data is still highly available and complex redeployment is unnecessary.
- Flexible consistency models for each app: There are five well-defined consistency choices: strong, bounded-staleness, session, consistent-prefix, and eventual. You have the option to choose the right one for your app.
- Iterating quickly without the worry of schemas and indexes: There’s nothing to worry about where schemas and indexes are concerned, as Azure Cosmos DB’s engine is schema-agnostic. Thus, there’s no application downtime while migrating schemasas they’re nonexistent. The result? Super fast queries.
- Using the right data model for your app: Azure Cosmos DB is built to support nearly any type of data model. The launch enables key-value, document, and graph models, but the engine is extensible and will continue to support newer types of models.
- Using APIs of your choice: Instead of relearning any type of code base, Azure Cosmos DB is intended to allow you to use the tools and APIs you already have familiarity with. It natively supports DocumentDB’s SQL dialect, MongoDB API, Gremlin (graph) API, and Azure Table Storage APIs. Other popular APIs will be added in the future.
- Industry leading comprehensive SLAs: Azure Cosmos DB is the first ever globally distributed database in the industry that offers financially backed comprehensive SLAs which cover high-availability, low latency, consistency, and throughput.
Azure Cosmos DB’s design goals
Based on Project Florence’s humble beginnings, Azure Cosmos DB intended to solve a multitude of problems.
- Enabling customers to elastically scale throughput and storage on demand globally: The guarantee was within 5 seconds at the 99th percentile from the time of request to delivery.
- Enabling customers to build highly responsive, mission critical apps: Thus, Azure Cosmos DB needed to deliver predictable and guaranteed end-to-end low read and write latencies at the 99th percentile.
- Ensuring that the system is always on: This requires 99.99% availability regardless of the number of regions chosen by developers. Developers were also made able to simulate regional failures and mark regions associate with their database offline. This validates end-to-end application properties.
- Enabling developers to write correct globally distributed applications: A predictable and intuitive model must be built around data consistency.
- Offer stringent financially-backed comprehensive SLAs: You pay for what you need.
- Relieve developers from the burden of database schema and index management and provisioning: Doing so was a pain in the ass, Microsoft admits.
- Natively support mutiple data models and popular APIs for accessing data: Externally exposed APIs and internal data representation needed to be efficient.
- Operating at a low cost: Keep the savings high for customers.
For a more technical overview of Azure Cosmos DB, check out this high level article.
Photo Credit: Shutterstock