1 unstable release
0.0.1 | Nov 30, 2024 |
---|
#24 in #resp
131 downloads per month
96KB
2K
SLoC
███████╗ ██████╗ ██████╗ ██████╗ █████╗ ██████╗ ██████╗ ██████╗
██╔════╝██╔═══██╗██╔═══██╗██╔══██╗██╔══██╗██╔══██╗ ██╔══██╗██╔══██╗
█████╗ ██║ ██║██║ ██║██████╔╝███████║██████╔╝ ██║ ██║██████╔╝
██╔══╝ ██║ ██║██║ ██║██╔══██╗██╔══██║██╔══██╗ ██║ ██║██╔══██╗
██║ ╚██████╔╝╚██████╔╝██████╔╝██║ ██║██║ ██║ ██████╔╝██████╔╝
╚═╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚═╝ ╚═╝ ╚═════╝ ╚═════╝
foobarDB
FoobarDB is an in-memory database implemented in Rust that supports the RESP V3 protocol. This project is for learning and research purposes. I aim to familiarize myself with Rust coding by implementing an in-memory database.
Features
- Supports RESP protocol
- Supports common Redis commands
- High performance and low latency
- Supports asynchronous operations
Prerequisites
- Rust 1.82.0
- Cargo package manager
Clone the repository
git clone https://github.com/yourusername/foobardb.git
cd foobardb
Build the project
cargo build --release
Usage
Start the server
cargo run --release --bin foobar_db
Client example
You can use any client that supports the RESP protocol to interact with FoobarDB. Here is a simple example using redis-cli
to connect to FoobarDB:
redis-cli -h 127.0.0.1 -p 6379
In redis-cli
, you can execute the following commands:
SET foo bar
GET foo
DEL foo
Contributing
We welcome contributions! Please follow these steps:
- Fork this repository
- Create your feature branch (
git checkout -b feature/fooBar
) - Commit your changes (
git commit -am 'Add some fooBar'
) - Push to the branch (
git push origin feature/fooBar
) - Create a new Pull Request
License
FoobarDB is licensed under the MIT License. For more information, please see the LICENSE file.
Authors
References
Dependencies
~11–21MB
~292K SLoC