Skip to content

A distributed, persistent key-value store for you to toy around.

Notifications You must be signed in to change notification settings

egnchen/NaiveKV

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NaiveKV

A distributed, persistent key-value store for you to toy around.

Structure overview

You can find detailed description and report in here, and the defense slides here.

Getting started

Compile protobuf

This project uses gRPC. To compile the proto buffer definitions, you'll need protoc and Go plugin for it. Check out https://grpc.io/docs/languages/go/quickstart/ for detail.

The gRPC stubs are precompiled & stored in proto. You can recompile your own with:

make proto

Start processes

This project uses zookeeper to maintain metadata, so start zookeeper first:

make zookeeper-create-network
make zookeeper

To start master server:

make master

To start primary worker server with id x:

make primary id=x

To start a backup server with id x:

make backup id=x

If you want to use multiple backups for one primary, specify backupNum. This parameter is used to determine the port the process uses, so it should be unique among backups of the same primary:

make backup id=x backupNum=y

To start a client, which is a REPL:

make client

To start a zookeeper CLI to see what's going on under the hood:

make zk-cli

About

A distributed, persistent key-value store for you to toy around.

Resources

Stars

Watchers

Forks

Packages

No packages published