{"id":47604159,"url":"https://github.com/alexpovel/miniraft","last_synced_at":"2026-04-01T19:01:34.062Z","repository":{"id":337261947,"uuid":"1126273638","full_name":"alexpovel/miniraft","owner":"alexpovel","description":"Raft consensus algorithm implementation for a key-value store. Dependency-free, stdlib only. Passes Jepsen Maelstrom chaos testing","archived":false,"fork":false,"pushed_at":"2026-01-24T18:18:25.000Z","size":617,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-02-08T22:07:37.185Z","etag":null,"topics":["distributed-systems","jepsen","jepsen-tests","raft","raft-consensus-algorithm","rust","stdlib"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/alexpovel.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-01-01T14:49:03.000Z","updated_at":"2026-01-18T13:29:08.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/alexpovel/miniraft","commit_stats":null,"previous_names":["alexpovel/miniraft"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/alexpovel/miniraft","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexpovel%2Fminiraft","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexpovel%2Fminiraft/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexpovel%2Fminiraft/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexpovel%2Fminiraft/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alexpovel","download_url":"https://codeload.github.com/alexpovel/miniraft/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexpovel%2Fminiraft/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31291009,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-01T13:12:26.723Z","status":"ssl_error","status_checked_at":"2026-04-01T13:12:25.102Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["distributed-systems","jepsen","jepsen-tests","raft","raft-consensus-algorithm","rust","stdlib"],"created_at":"2026-04-01T19:00:57.822Z","updated_at":"2026-04-01T19:01:34.037Z","avatar_url":"https://github.com/alexpovel.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# miniraft\n\nAn implementation of the [Raft distributed consensus\nprotocol](https://raft.github.io/raft.pdf) for powering a key-value workload (read,\nwrite, CAS).\n\n- **dependency-free**, stdlib-only Rust (cold, release compile in ~1s)\n  - [**custom JSON parser**](json/src/lib.rs) and ser/de framework, with OK performance\n    (ballpark of ~220 MB/s throughput on Apple M3 on [complex\n    input](json/benches/bench.rs) (UTF-16 surrogate etc.)) and **full spec compliance**,\n    passing [JSON minefield stress test\n    suite](https://seriot.ch/software/parsing_json.html)\n  - [base64 non-URL](base64/src/lib.rs)\n  - [`rand` helper](rand/src/lib.rs) (Unix only)\n  - [Prometheus-style metrics](raft/src/metrics/mod.rs)\n    ([example](docs/images/term-metrics.png); `n1` stepping its term during a partition)\n    with a simple HTTP/1.1 server\n- Raft implementation passes [Jepsen Maelstrom chaos\n  testing](https://github.com/jepsen-io/maelstrom), for the [**linearizable** KV\n  workload](docs/images/raft-kv-latencies-under-network-partition.png) (the failures in\n  the graph are expected, it is Jepsen probing for linearizability)\n    - **fully generic (literally and design-wise) core Raft**: applicable to _any_\n      workload backable by Raft; the core just holds opaque commands in its log, with an\n      abstract state machine dependency-injected for committing into\n    - channel-based glue layer to translate between KV RPCs and Raft core; enables\n      pluggable I/O\n    - focus on correctness: [illegal states made\n      unrepresentable](https://cliffle.com/blog/rust-typestate/) levering the type\n      system where feasible, and liberal use of `assert`s for pre/post conditions. No\n      `unsafe`, no shenanigans\n\n## Not in the box\n\n- TCP/HTTP: I/O and [the binary](raft/src/main.rs) are specific to Jepsen\n  Maelstrom, but that's just a couple hundred lines\n- async: stdlib-only, so threading is used.\n\n  This is implemented asynchronously and non-blocking all the same: client and Raft RPCs\n  can be emitted and received at any time. Awaiting responses to emitted RPCs is\n  asynchronous as well, though messages go into single-receiver queues. That serializes\n  requets, but the necessary mutual exclusion on the core Raft state does so anyway\n  (there is only one lock, which incidentally makes deadlock-freedom much simpler to\n  guarantee!)\n- live cluster configuration changes\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexpovel%2Fminiraft","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falexpovel%2Fminiraft","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexpovel%2Fminiraft/lists"}