Skip to Content
数据库系统内幕
book

数据库系统内幕

by Alex Petrov
May 2020
Beginner to intermediate
319 pages
7h 3m
Chinese
China Machine Press
Content preview from 数据库系统内幕
共识
|
269
为了证明这些状态是正确的,节点计算出到某个给定序列号为止的消息的状态。节点可
以比较摘要、验证状态的完整性,以及确保恢复过程中收到的消息加在一起达到的最终
状态是正确的。这一过程太昂贵,无法为每个请求执行。
每隔 N 个请求(N 是可配置的常量),主节点会创建一个
稳定检查点
(stable checkpoint):
它广播一个最新序列号(标识执行结果已被反映在状态中的最后一个请求)以及相应状
态的摘要。然后,它等待 2f + 1 个副本响应,这些响应构成了该检查点的证明,保证
各副本可以安全地丢弃给定序列号之前的所有预准备、准备、提交和检查点消息。
理解拜占庭容错性很重要,它被用在有潜在对抗性的网络中的存储系统上。大多数时
候,对节点间通信进行身份验证和加密就足够了,但是当系统各部分之间没有信任时,
必须采用类似 PBFT 的算法。
容忍拜占庭故障的算法会带来显著的消息交换开销,因此,了解这些算法的使用场景格
外重要。文献 [BAUDET19] 和文献 [BUCHMAN18] 中还提到了一些其他协议,它们尝
试为包含大量参与者的系统优化 PBFT 算法。
14.6
本章小结
共识算法是分布式系统中最有趣的也是最复杂的主题之一。过去的几年中,涌现出了许
多新算法以及现有算法的多种实现,这证明了共识算法的重要性和流行程度日渐增长。
在本章中,我们讨论了经典 Paxos 算法以及 Paxos 的几个变体,每个变体都对不同的特
性进行了改进:
Multi-Paxos
允许提议者保留这一角色,提议多个值而不是一个。 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

解密金融数据

解密金融数据

Justin Pauley

Publisher Resources

ISBN: 9787111655169