Giter Club home page Giter Club logo

raft's Introduction

raft

This is an implementation of the Raft distributed consensus protocol. It's heavily influenced by benbjohnson's implementation. It focuses on providing a clean and usable API, and well-structured internals.

Build Status

Usage

A node in a Raft network is represented by a Server structure. In a typical application, nodes will create a Server, and expose it to other nodes using a Peer interface.

Servers are only useful when they can communicate with other servers. This library includes a HTTP Transport (ingress) and HTTP Peer (egress) which combine to allow communication via REST-ish endpoints. For now, it's the simplest way to embed a Raft server in your application. See this complete example.

Several other transports are coming; see TODO, below.

Adding and removing nodes

The Raft protocol has no affordance for node discovery or "join/leave" semantics. Rather, the protocol assumes an ideal network configuration that's known a priori to nodes in the network, and describes a mechanism (called joint-consensus) to safely replicate that configuration.

My implementation of joint-consensus abides those fundamental assumptions. Nodes may be added or removed dynamically by requesting a SetConfiguration that describes a complete network topology.

TODO

  • Leader election done
  • Log replication done
  • Basic unit tests done
  • HTTP transport done
  • net/rpc transport
  • Other transports?
  • Configuration changes (joint-consensus mode) done
  • Log compaction
  • Robust demo application ☜ in progress
  • Complex unit tests (one per scenario described in the paper)

raft's People

Contributors

peterbourgon avatar bernerdschaefer avatar garyburd avatar tv42 avatar

Stargazers

devang desai avatar xiazemin avatar Tu Hoang avatar Vineed Kaladharan avatar  avatar Osi Emoekpere avatar Quang Tùng avatar Farhan avatar  avatar Hou 42 avatar zhuokuny avatar WellOptimized avatar Mo Nguyen avatar Panda avatar Yiliang Qiu avatar Cary avatar Hossein avatar wuxingyi avatar James Yang avatar  avatar djangoli avatar Rick avatar SUTIRTHA GHOSH avatar Aveena Kottwani avatar huang yan avatar 秦世成 avatar LIU Yu avatar  avatar David McElligott avatar Lyiker avatar Kangcheng Xu avatar Haipeng Zhang avatar Alexandre Fiori avatar rtee+ avatar zbv avatar  avatar William Storey avatar James Mills avatar Tianle Xu avatar  avatar Trang Mai avatar YNX avatar Vimlesh Sharma avatar  avatar 飞刀 avatar feifeiiiiiiiiii avatar mike avatar Zhao Jiangkun avatar  avatar Winter Snow avatar dzdx avatar  avatar Amit D. avatar  avatar geemo avatar Ilya Kaplun avatar  avatar Sean Graham avatar Ritchie J. Latimore avatar kapilkchaurasia avatar  avatar w avatar liaoyw avatar kepler avatar No.20 avatar Jim K avatar Jacob Blain Christen avatar Jusfly avatar Victor avatar Kasper Isager Dalsgarð avatar  avatar MilkyStan avatar Andrey Sinitsyn avatar pmontaigne avatar  avatar YuJie avatar Lin RuiChao avatar Aayush Shah avatar irfan sharif avatar grapeVine avatar Xiaohan Song avatar Caio Pereira Oliveira avatar Eugene avatar Miki Oracle avatar Herby Gillot avatar Jim Schubert avatar Jayden.Lie avatar Dragos STOICA avatar Vignesh Mohankumar avatar  avatar  avatar Terry avatar Jake Myers avatar Angus H. avatar Darren Hoo avatar Isagani Mendoza avatar johntech avatar Anders Brander avatar Alix Axel avatar  avatar

Watchers

Jianfei Wang avatar  avatar maxminflow avatar evandrix avatar Dimitar9 avatar James Cloos avatar  avatar  avatar Nick Owens avatar Perry Birch avatar  avatar Mamunar Rashid avatar johntech avatar Tenz avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.