``` Stonebraker 关于 CAP 定理和数据库 ```
Stonebraker on CAP theorem and Databases (2010)

原始链接: https://perspectives.mvdirona.com/2010/04/stonebraker-on-cap-theorem-and-databases/

詹姆斯·汉密尔顿讨论了迈克·斯通布雷克最近的一篇博文,该文挑战了NoSQL数据库中基于CAP定理的最终一致性广泛应用。斯通布雷克认为,CAP无法保护免受常见的数据丢失场景,例如应用程序错误、管理失误或数据库错误——因这些问题导致的数据丢失,无论一致性模型如何,都将永久丢失。 汉密尔顿表示同意,提倡使用“延迟删除”等技术进行数据恢复,并强调完全一致性通常可以在规模上实现,并且是*期望的*,甚至指出Amazon SimpleDB最近对其的支持。他指出,通常被引用为最终一致性理由的网络分区,其发生频率低于由不可靠网络设备引起的相关网络问题。 最终,双方都认为不应过早地否定完全一致性,因为它能够简化应用程序开发并减少错误,并且不一定会牺牲可扩展性。

黑客新闻 新 | 过去 | 评论 | 提问 | 展示 | 招聘 | 提交 登录 Stonebraker 关于 CAP 定理和数据库 (mvdirona.com) 7 分,来自 onurkanbkrc 1 小时前 | 隐藏 | 过去 | 收藏 | 1 条评论 nine_k 11 分钟前 [–] 简而言之:在许多现实世界的错误场景中,最终一致性是不够的,这些场景超出了 CAP 定理的范围。在可能的情况下,选择完全一致性,这比通常认为的实际情况更多。回复 指南 | 常见问题 | 列表 | API | 安全 | 法律 | 申请 YC | 联系方式 搜索:
相关文章

原文

Mike Stonebraker published an excellent blog posting yesterday at the CACM site: Errors in Database Systems, Eventual Consistency, and the CAP Theorem. In this article, Mike challenges the application of Eric Brewer’s CAP Theorem by the NoSQL database community. Many of the high-scale NoSQL system implementers have argued that the CAP theorem forces them to go with an eventual consistent model.

Mike challenges this assertion pointing that some common database errors are not avoided by eventual consistency and CAP really doesn’t apply in these cases. If you have an application error, administrative error, or database implementation bug that losses data, then it is simply gone unless you have an offline copy. This, by the way, is why I’m a big fan of deferred delete. This is a technique where deleted items are marked as deleted but not garbage collected until some days or preferably weeks later. Deferred delete is not full protection but it has saves my butt more than once and I’m a believer. See On Designing and Deploying Internet-Scale Services for more detail.

CAP and the application of eventual consistency doesn’t directly protect us against application or database implementation errors. And, in the case of a large scale disaster where the cluster is lost entirely, again, neither eventual consistency nor CAP offer a solution. Mike also notes that network partitions are fairly rare. I could quibble a bit on this one. Network partitions should be rare but net gear continues to cause more issues than it should. Networking configuration errors, black holes, dropped packets, and brownouts, remain a popular discussion point in post mortems industry-wide. I see this improving over the next 5 years but we have a long way to go. In Networking: the Last Bastion of Mainframe Computing, I argue that net gear is still operating on the mainframe business model: large, vertically integrated and expensive equipment, deployed in pairs. When it comes to redundancy at scale, 2 is a poor choice.

Mike’s article questions whether eventual consistency is really the right answer for these workloads. I made some similar points in “I love eventual consistency but…” In that posting, I argued that many applications are much easier to implement with full consistency and full consistency can be practically implemented at high scale. In fact, Amazon SimpleDB recently announced support for full consistency. Apps needed full consistency are now easier to write and, where only eventual consistency is needed, its available as well.

Don’t throw full consistency out too early. For many applications, it is both affordable and helps reduce application implementation errors.

–jrh

Thanks to Deepak Singh for pointing me to this article.

James Hamilton

e: [email protected]

w: http://www.mvdirona.com

b: http://blog.mvdirona.com / http://perspectives.mvdirona.com

联系我们 contact @ memedata.com