Consistency Level Behavior in Azure Cosmos DB (MongoDB API)

Wong, Joey 0 Reputation points
2024-11-13T20:17:49.5033333+00:00

From the information available in the documentation,

  • "Session" consistency is not supported by MongoDB.
  • The write concern is mapped using these three consistency levels: strong => majority, bounded stateless => minority, consistent prefix => None.

If the consistency level in Cosmos DB is set to "Session," does it fall back to one of these three options (strong/bounded stateless/consistent prefix), or does it exhibit different behavior?

Azure Cosmos DB
Azure Cosmos DB
An Azure NoSQL database service for app development.
1,681 questions
{count} votes

1 answer

Sort by: Most helpful
  1. ShaktiSingh-MSFT 15,766 Reputation points
    2024-11-14T04:29:55.4033333+00:00

    Hi Wong, Joey •,

    Welcome to Microsoft Q&A forum.

    As I understand, you want to know if the consistency level in Cosmos DB is set to "Session," does it fall back to one of these three options (strong/bounded stateless/consistent prefix), or does it exhibit different behavior in Mongo DB (Azure Cosmos DB).

    The default consistency model for Azure Cosmos DB is Session.

    Session is a client-centric consistency model which is not natively supported by either Cassandra or MongoDB.

    For more information on which consistency model to choose see, Consistency levels in Azure Cosmos DB

    Let me know if your ask is different to what we understood.

    Thanks

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.