Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

💡 Feature Request - DocumentDB/databaseAccounts CosmoDB recommendations #247

Closed
FallenHoot opened this issue Jul 1, 2024 · 3 comments
Assignees
Labels
Area: Resource Guidance 📝 Improvements or additions to documentation Bug 🐞 Something isn't working Enhancement 🆕 New feature or request

Comments

@FallenHoot
Copy link
Contributor

FallenHoot commented Jul 1, 2024

Describe the solution you'd like

If Cosmo DB NoSQL is using Multi-Region Writes, then it is recommended by Microsoft to not enable Availability Zone support as it provides limited value. As documented in the learn docs. Following the guidance shared in - the learn docs around the impact of using availability zones with Multi-Region Writes enabled. AZs for Multi-Region writes are free, and it is assumed having them turned on doesn't affect the reliability of Cosmo DB when using Multi-Region Writes.

It should be noted that having AZ enabled only is recommended if strong consistency is being used. Multi-Region Writes do not support strong consistency.

Cosmos DB accounts configured with multiple write regions can't be configured for strong consistency as it isn't possible for a distributed system to provide an RPO of zero and an RTO of zero.

I have also updated the wording in the learn docs to reflect this - MicrosoftDocs/azure-docs#123628

Recommendation:
The feature request is two folds: If Multi-Region writes is enabled, then AZs are grayed out, as they provide limited value.

Describe alternatives you've considered

No alternatives

Additional context

All context is added to the above.

@ejhenry
Copy link
Contributor

ejhenry commented Jul 1, 2024

@kovarikthomas please review

@oZakari oZakari added the Area: Resource Guidance 📝 Improvements or additions to documentation label Jul 2, 2024
@oZakari oZakari added the Bug 🐞 Something isn't working label Jul 2, 2024
@kovarikthomas
Copy link
Contributor

Hi Zach (@FallenHoot) and Eric (@ejhenry) - while I do not know where you would like to "gray out" the AZ option (Portal, docs, someplace else?), I would prefer we do not do it anywhere.

"it is recommended by Microsoft to not enable Availability Zone support as it provides limited value"

Rather than recommending against AZs, the referenced docs point at diminishing returns from enabling AZs if other resiliency features/options are also used - e.g., multiple read regions, or multi-region writes. In all cases, AZs are beneficial, and as you mentioned, with multi-region writes, they come for free. As long as the given Azure region supports AZs and there's sufficient capacity, customers should absolutely enable them.

To be specific, for multi-region writes configured accounts AZs are still beneficial when outage occurs on:

  • conflict-resolution region, which is exactly one of configured regions - in such a case, temporary loss of write availability occurs until new conflict resolution region is elected (refer: docs). With AZs enabled all four replicas are spread across all available zones which ensures that in the event of an outage in one AZ, the account remains fully operational and conflict resolution region election is not required. In contrast, without AZs, all replicas would be located in a single AZ (we do not expose which), leading to potential downtime if that specific zone experienced an issue.
  • any non-conflict resolution region - assuming AZs are not used and that particular AZ hosting all replicas experiences an outage, account will seamlessly and instantaneously retry operations on other regions (as defined in Preferred Regions list, refer docs). While this limits/eliminates any downtime, CRUD operations now experience higher latency due to calls being made across Azure regions. With AZs enabled, Cosmos DB would dynamically downshift quorum and calls would continue to be served with low latency from the unaffected AZs in the original region.

@ejhenry
Copy link
Contributor

ejhenry commented Aug 5, 2024

Thanks @kovarikthomas. @FallenHoot any concerns with closing this issue?

@ejhenry ejhenry closed this as completed Aug 28, 2024
@microsoft-github-policy-service microsoft-github-policy-service bot added the Enhancement 🆕 New feature or request label Aug 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Resource Guidance 📝 Improvements or additions to documentation Bug 🐞 Something isn't working Enhancement 🆕 New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants