8000 GitHub - deepPublicGit/godis: Exploring Redis implementation in Go. · GitHub
[go: up one dir, main page]

Skip to content
deepPublicGitPublic

About

Exploring Redis implementation in Go.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

27 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Godis

A Redis server implementation in Go.

Description

Godis is a lightweight Redis-like server written in Go. It implements the Redis Serialization Protocol (RESP) and provides a TCP server that can process Redis commands.

Installation

# Clone the repository
git clone https://github.com/yourusername/godis.git

# Navigate to the project directory
cd godis

# Build the project
go build

Usage

# Run the server with default settings (127.0.0.1:8080)
./godis

# Run the server with custom host and port
./godis -h 0.0.0.0 -p 6379

You can connect to the server using any Redis client, or use a simple TCP client like netcat:

nc 127.0.0.1 8080

Project Status

This project is in early development. The basic server structure is in place, but many features are not yet implemented.

Todo List

  • Fix bugs in the RESP decoder:
    • Fix DecodeCommands function which currently always returns nil
    • Fix panics
    • Fix bug with INCR/DECR and SET
  • Implement async server based on eventloop
  • Add support for windows based on IOCP
  • Implement RESP encoder for proper response formatting
  • Implement command evaluation logic
  • Add data storage functionality
  • Implement basic Redis commands:
    • GET
    • SET
    • DEL
    • TTL
    • INCR
    • DECR
    • EXPIRE
  • Improve Naive Implementation of Delete & Expiry
  • Add support for Eviction Policies
    • LRU
    • LFU
    • Approximate LRU
    • Random
  • Incorporate design pattern for choosing eviction strategies.
  • Add config file and refactor argument flags
  • Add command chaining
  • Add support for data types/structures:
    • Strings
    • Lists
    • Sorted Sets
    • Geo Hash
    • HyperLogLog
  • Improve Naive Implementation of Delete & Expiry
  • Improve error handling
  • Add integration tests
  • Add benchmarking
  • Add Redis CLI using Charm / Bubble Tea
  • Add persistence options
  • Add transactions
  • Improve documentation

Contributing

Contributions are welcome! Please feel free to submit issues.

About

Exploring Redis implementation in Go.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages

0