सभी किताबें

पेशेवर

1 Markets I: The Ecosystem and Exchange-Traded Marketsबाज़ार ऑनलाइन 2 Markets II: Rates, FX and Creditबाज़ार ऑनलाइन 3 Markets III: Commodities, Energy and Cryptoबाज़ार ऑनलाइन 4 Quantitative Methodsविधियाँ ऑनलाइन 5 Derivatives and Volatilityडेरिवेटिव्स ऑनलाइन 6 Rates, Credit, XVA and Riskब्याज दरें, क्रेडिट और जोखिम ऑनलाइन 7 Research Craft: Predictors, Backtests, Measurement, Portfoliosअनुसंधान ऑनलाइन 8 Strategies I: Equities and Futuresरणनीतियाँ ऑनलाइन 9 Strategies II: Volatility, Relative Value, Macro and the Bank Desksरणनीतियाँ ऑनलाइन 10 Microstructure and Executionनिष्पादन ऑनलाइन 11 Market Making and High-Frequency Tradingमार्केट मेकिंग ऑनलाइन 12 Machine Learning for Marketsमशीन लर्निंग ऑनलाइन 13 Low-Latency Softwareतकनीक ऑनलाइन 14 Networks, Hardware and Trading Infrastructureतकनीक ऑनलाइन 15 Research, Data and Risk Platformsतकनीक ऑनलाइन 16 The Desk and the Firmफ़र्म ऑनलाइन 17 The Industry: Firms, Roles and Careersकरियर ऑनलाइन 18 Interviews I: Maths, Probability and Speedकरियर ऑनलाइन 19 Interviews II: Markets, Trading Games and the Final Roundकरियर ऑनलाइन 20 Interviews III: Codeकरियर ऑनलाइन
ऐप्स परिचय Coach लॉग इन पढ़ना शुरू करें

Computer Science · शब्दावली

Raft, election term, leader election, replicated log, log matching property, commit index क्या है?

अन्य नाम: Raft · election term · leader election · replicated log · commit index · log matching property

Definition 26.8 University Computer Science — Year 3 · अध्याय 26 — Replication and Consensus

Raft is a protocol for state-machine replication among NN servers, each a follower, a candidate or a leader. Time is divided into election terms, numbered 1,2,…1, 2, \ldots; every message carries its sender’s election term, and a server that sees a larger one adopts it and becomes a follower. In a leader election, a follower that has heard from no leader for a random timeout starts a new election term, votes for itself and asks the others for their votes; each server votes at most once per election term, only for a candidate whose log is at least as up to date as its own (larger last election term, or the same and at least as long), and a candidate with votes from a majority becomes leader. The replicated log is each server’s sequence of entries, each a command with the election term in which a leader created it. The leader appends client commands to its log and sends each follower the entries it lacks, with the index and election term of the entry just before them; a follower accepts only if its own log has that entry, and replaces any conflicting entries. The commit index is the largest index known to be committed: the leader commits an entry of its own election term once a majority store it, and with it every entry before it. The log matching property states that if two logs have an entry with the same index and election term, they are identical up to that index.

The three roles of a Raft server. Only a follower or a candidate moves on its own, at a timeout; every other move, and every move of the leader, is caused by a message.
The three roles of a Raft server. Only a follower or a candidate moves on its own, at a timeout; every other move, and every move of the leader, is caused by a message.
The logs of , each entry written as election term:command. Before the change, S5’s sixth entry exists only in its own log, and S2 missed three entries while down. After it, S3’s entries of election term 3 have replaced S5’s uncommitted entry, and S2 has caught up.
The logs of Output 26.4, each entry written as election term:command. Before the change, S5’s sixth entry exists only in its own log, and S2 missed three entries while down. After it, S3’s entries of election term 3 have replaced S5’s uncommitted entry, and S2 has caught up.
अध्याय में पढ़ें →