# etcd-io/raft

Raft library for maintaining a replicated state machine

Repository: https://github.com/etcd-io/raft
Canonical: https://ross.abutalabs.com/products/etcd-io-raft
Language: Go
License: Apache-2.0
License Family: permissive
Topics: raft, distributed-systems, consensus
Last push: 2026-09-02T08:50:55+00:00

## Health v2 (maintenance only)
Score: 85/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 100, release rhythm 58, longevity 98
- inputs: {"age_days": 1375, "days_push": 0, "days_rel": 71, "gap_med": 502, "n_releases_24m": 2}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1107, forks 270 (observed 2026-09-03T02:15:11.747980+00:00)

## What it is
A Go library implementing the core Raft consensus algorithm for maintaining a replicated state machine across a cluster of nodes. It deliberately excludes networking and storage, leaving transport and persistence layers to the user for maximum flexibility and determinism.

## Use cases
- build a replicated state machine with raft consensus
- implement leader election and log replication in a distributed system
- add consensus to a distributed database or key-value store
- implement linearizable read-only queries in a cluster
- learn how the raft consensus algorithm works in production code

## When to choose
- you need a battle-tested, production-proven raft implementation powering etcd, Kubernetes, CockroachDB, and TiDB
- you want full control over networking and storage layers
- you need a deterministic, minimal core algorithm library
- you need advanced features like membership changes, leadership transfer, and log compaction

## When to avoid
- you want an out-of-the-box distributed system with networking and storage included
- you need a monolithic raft solution with built-in transport
- your project is not written in Go

## Facets
- artifact type: library
- maturity: stable
- function: concurrency, developer-tools
- domain: microservices, databases
- platform: go, cross-platform
- tags: raft, consensus, replicated-log, distributed-consensus, state-machine-replication, algorithms

## Member repositories
- etcd-io/raft (main) score 85

## Provenance
- Observed fields: from GitHub, fetched 2026-09-03T02:15:11.747980+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T06:46:18.568498+00:00, confidence not recorded.
  - readme: https://github.com/etcd-io/raft (fetched 2026-09-03T02:15:11.747980+00:00, sha c0ebf0434fb6)
- Data as of 2026-08-30T08:39:29.467469+00:00.
