【Hacker News搬运】CAP定理的图解证明(2018)
-
Title: An illustrated proof of the CAP theorem (2018)
CAP定理的图解证明(2018)
Text:
Url: https://mwhittaker.github.io/blog/an_illustrated_proof_of_the_cap_theorem/
很抱歉,我无法直接访问或分析外部网站的内容。但是,我可以根据您提供的链接描述和我的知识来帮助您。 链接指向的是一个博客文章,标题为 "An Illustrated Proof of the CAP Theorem"(CAP定理的图解证明)。CAP定理是分布式计算领域的一个基本概念,它阐述了在分布式系统中,一致性(Consistency)、可用性(Availability)和分区容错性(Partition tolerance)这三个特性不能同时被完全满足。这个定理是由Eric Brewer在2000年提出的。 以下是对该博客文章内容的可能总结(基于标题和CAP定理的描述): 这篇文章可能通过图解的方式展示了CAP定理的证明。图解通常能够以直观的方式解释复杂的理论,使读者更容易理解。以下是对文章可能内容的概述: 1. **CAP定理的定义**:文章可能首先介绍了CAP定理的基本概念,即在一个分布式系统中,只能在一致性、可用性和分区容错性中选择两个特性。 2. **一致性**:解释了一致性的含义,即在所有节点上数据都是一致的,即使网络发生分区。 3. **可用性**:描述了可用性的概念,即系统在接收到请求时必须给出响应,无论请求是否成功。 4. **分区容错性**:讨论了分区容错性,即在发生网络分区时,系统仍然能够继续运行。 5. **图解证明**:文章的核心部分可能通过一系列的图解来展示如何证明这三个特性不能同时实现。图解可能包括不同的分布式系统模型和它们在不同网络条件下的行为。 6. **实际应用**:最后,文章可能讨论了CAP定理在实际分布式系统设计中的应用,以及如何在不同的场景下权衡这三个特性。 如果您需要对该博客文章的具体内容进行翻译或深入分析,我建议您直接访问该链接阅读文章内容。如果您有任何具体问题或需要帮助理解CAP定理,我会尽力提供帮助。
Post by: tripdout
Comments:
refibrillator: CAP theorem is great, though it does omit latency. Which leads you to the logical extension, PACELC [1]:<p>If there is a network Partition you must choose Availability or Consistency, Else the tradeoff is Latency vs Consistency.<p>This offers practical intuition for certain design choices.<p>For example Google Spanner [2] is a distributed DB that offers globally consistent reads/writes, but to achieve high performance (low latency) nodes must synchronize with multiple extremely accurate reference clocks (GPS & atomic) and follow a complex two phase commit protocol that ensures transactional linearizability using lower bounds and uncertainty of timestamps.<p>As another example, your multicore CPU leverages a cache coherency protocol that faces remarkably similar tradeoffs. Perhaps others have made this connection before…it does feel like some sort of universal law of physics.<p>[1] <a href="https://en.m.wikipedia.org/wiki/PACELC_theorem" rel="nofollow">https://en.m.wikipedia.org/wiki/PACELC_theorem</a><p>[2] <a href="https://static.googleusercontent.com/media/research.google.com/en//archive/spanner-osdi2012.pdf" rel="nofollow">https://static.googleusercontent.com/media/research.google.c...</a>
refibrillator:
vzaliva: The text left me wanting a more formal treatment of the theorem. I went ahead and found a paper which does just that:<p><a href="https://dl.acm.org/doi/10.1145/564585.564601" rel="nofollow">https://dl.acm.org/doi/10.1145/564585.564601</a>
PDF: <a href="https://users.ece.cmu.edu/~adrian/731-sp04/readings/GL-cap.pdf" rel="nofollow">https://users.ece.cmu.edu/~adrian/731-sp04/readings/GL-cap.p...</a>vzaliva: 这篇文章让我想对定理进行更正式的处理。我继续前进,发现了一篇这样的论文:<p><a href=“https:/;dl.acm.org&#doi=10.1145򉵩.564601”rel=“nofollow”>https:/;dl.acm.org;doi;10.1145℉;564585.564601</a>PDF:<a href=“https:”users.ece.cmu.edu“~ adrian”731-sp04“readings”GL cap.PDF“rel=”nofollow“>https:”/;users.ece.cmu.edu~阿德里安;731-sp04;读数;GL盖</a>
jascha_eng: This is trivial but the problem is that especially consistency is not a binary choice. Heck even non distributed systems can give you varying consistency guarantees it's the whole point of isolation levels of most RDBMS.<p>It's good to visualize that there is a trade off to be made. However that trade off does not have to be binary. You can get a bit more consistency for a little less partition tolerance or availability. All of Designing data intensive applications is about those trade offs.
jascha_eng: 这是微不足道的,但问题是,尤其是一致性不是二元选择。见鬼,即使是非分布式系统也可以为您提供不同的一致性保证;这是大多数RDBMS隔离级别的全部要点。<p>;很高兴能想象到需要做出权衡。然而,这种权衡不一定是二元的。您可以通过降低分区容忍度或可用性来获得更高的一致性。所有设计数据密集型应用程序都是关于这些权衡。
dang: Related:<p><i>An Illustrated Proof of the CAP Theorem</i> - <a href="https://news.ycombinator.com/item?id=17528817">https://news.ycombinator.com/item?id=17528817</a> - July 2018 (71 comments)
dang: 相关:<p><i>CAP定理的图解证明</i>-<a href=“https:/;/ news.ycombinator.com/-item?id=17528817”>https:/;news.ecombinator.com;项目?id=17528817</a>-2018年7月(71条评论)
magnio: The "proof" is kind of weird. We assume there exists a system that has all three of CAP, but how can we assume that system has the layout in the post with two servers and one client?
magnio: ";证明";有点奇怪。我们假设存在一个具有所有三个CAP的系统,但我们如何假设该系统在帖子中具有两个服务器和一个客户端的布局?