A course to build distributed key-value service based on TiKV model
Go to file
Connor 5e089a2cd1 init course framework
Signed-off-by: Connor <zbk602423539@gmail.com>
Co-authored-by: Nick Cameron <nrc@ncameron.org>
Co-authored-by: linning <linningde25@gmail.com>
Co-authored-by: YangKeao <keao.yang@yahoo.com>
Co-authored-by: andylokandy <andylokandy@hotmail.com>
Co-authored-by: Iosmanthus Teng <myosmanthustree@gmail.com>
2020-04-30 15:25:07 +08:00
.github/workflows init course framework 2020-04-30 15:25:07 +08:00
kv init course framework 2020-04-30 15:25:07 +08:00
log init course framework 2020-04-30 15:25:07 +08:00
proto init course framework 2020-04-30 15:25:07 +08:00
raft init course framework 2020-04-30 15:25:07 +08:00
scheduler init course framework 2020-04-30 15:25:07 +08:00
.gitignore init course framework 2020-04-30 15:25:07 +08:00
go.mod init course framework 2020-04-30 15:25:07 +08:00
go.sum init course framework 2020-04-30 15:25:07 +08:00
Makefile init course framework 2020-04-30 15:25:07 +08:00
README.md init course framework 2020-04-30 15:25:07 +08:00

The TinyKV LAB

This is a series of labs on a key-value storage system built with the Raft consensus algorithm. These labs are inspired by the famous MIT 6.824 course, but aim to be closer to industry implementations. The whole lab is pruned from TiKV and re-written in Go. After completing this course, you will have the knowledge to implement a basic key-value storage service with distributed transactions and fault-tolerance and better understanding of TiKV implementation.

The whole project is a skeleton code for a kv server and a scheduler server at initial, and you need to finish the core logic step by step:

  • LAB1: build a standalone key-value server
  • LAB2: build a fault tolerant key-value server with Raft
  • LAB3: support multi Raft group and balance scheduling on top of LAB2
  • LAB4: support distributed transaction on top of LAB3

Important note: This course is still in developing, and the document is incomplete. Any feedback and contribution is greatly appreciated. Please see help wanted issues if you want to join in the development.

Build

make

Test

make test

Run(Not runnable now)

Put the binary of tinyscheduler-server, tinykv-server and tidb-server into a single dir.

Under the binary dir, run the following commands:

mkdir -p data
./tinyscheduler-server
./tinykv-server --db-path=data
./tinysql-server --store=tikv --path="127.0.0.1:2379"

Documentation(Incomplete)

This repo contains a single module: tinykv. Each package is documented either in a doc.go file or, if it is a single file package, in the single file.

See doc.go for top-level documentation.