'How atom-record-sequence (ARS) helps CosmosDB to be Multimodel?

Can anyone explain how atom-record-sequence (ARS) works and how it helps CosmosDB to support multiple models without "performance penalties"?

So far, the best answer I found about it was this one What does it mean that Azure Cosmos DB is multi-model?



Solution 1:[1]

You can write data in SQL API and read it in Gremlin API as a graph. If it wasn't for ARS, it would not be possible. The goal of Cosmos DB is to have all its APIs fully inter-operable like this and ARS is the foundational piece to make it happen.

Solution 2:[2]

This article explains it well:

https://azure.microsoft.com/en-gb/blog/a-technical-overview-of-azure-cosmos-db/

Although I think you'll still have concerns over its "performance penalties".

I feel that this is a solution that works when you throw enough hardware at it. As such I am still a little uneasy at depending on such a solution, even though I'd just have to pay someone else to do the hardware-throwing. Ignorance is not bliss.

Solution 3:[3]

The core type system of Azure Cosmos DB’s database engine is atom-record-sequence (ARS) based. Atoms consist of a small set of primitive types e.g. string, bool, number etc., records are structs and sequences are arrays consisting of atoms, records or sequences. The database engine of Azure Cosmos DB is capable of efficiently translating and projecting the data models onto the ARS based data model. The core data model of Azure Cosmos DB is natively accessible from dynamically typed programming languages and can be exposed as-is using JSON or other similar representations. The design also enables natively supporting popular database APIs for data access and query.

Azure Cosmos DB uses an atom-record-sequence (ARS) system. Basically, the Cosmos DB translates all data models into atom-record-sequence based models.

So, everything becomes either an atom, a record or a sequence.

An atom is a primitive type. A record is a struct A sequence is an array of either atoms, records or structs. At the moment Azure Cosmos DB supports

Key-value pairs Column family Document and Graph enter image description here

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 alekseys
Solution 2 Raith
Solution 3 Petronella