Open source Java implementation for Raft consensus protocol.

Clone this repo:
  1. b31153b RATIS-2682. Use the original Raft group for client retries in testKillLeaderDuringReconf (#1578) by slfan1989 · 3 days ago master
  2. 0cbb555 RATIS-2218. Remove stale flaky annotation from TestMultiRaftGroup. (#1576) by slfan1989 · 5 days ago
  3. 657ab9e RATIS-2677. Replace redundant setFirstRequest() call with an assertion (#1575) by lugency · 6 days ago
  4. 86ace58 RATIS-2680. Maintain backward compatibility for cleanupOldSnapshots (#1569) by Rui Wang · 6 days ago
  5. 3a9bf59 RATIS-2262. Fix flaky testStateMachineMetrics (#1572) by slfan1989 · 6 days ago

Apache Ratis

Apache Ratis is a Java library that implements the Raft protocol [1], where an extended version of the Raft paper is available at https://raft.github.io/raft.pdf. The paper introduces Raft and states its motivations in following words:

Raft is a consensus algorithm for managing a replicated log. It produces a result equivalent to (multi-)Paxos, and it is as efficient as Paxos, but its structure is different from Paxos; this makes Raft more understandable than Paxos and also provides a better foundation for building practical systems.

Ratis aims to make Raft available as a java library that can be used by any system that needs to use a replicated log. It provides pluggability for state machine implementations to manage replicated states. It also provides pluggability for Raft log, rpc implementations and metric implementations to make it easy for integration with other projects. Another important goal is to support high throughput data ingest so that it can be used for more general data replication use cases.

Reference

  1. Diego Ongaro and John Ousterhout, In Search of an Understandable Consensus Algorithm, 2014 USENIX Annual Technical Conference (USENIX ATC 14) (Philadelphia, PA), USENIX Association, 2014, pp. 305-319.