An open API service indexing awesome lists of open source software.

https://github.com/botirk38/fastkey

A high-performance key-value store built with C, utilizing a thread pool for concurrency and the RESP protocol for communication.
https://github.com/botirk38/fastkey

Last synced: about 2 months ago
JSON representation

A high-performance key-value store built with C, utilizing a thread pool for concurrency and the RESP protocol for communication.

Awesome Lists containing this project

README

        

# Fastkey Project

## Project Overview
Fastkey is a high-performance, scalable, and concurrent key-value store written in C. It leverages Redis for optimized performance and scalability.

### Key Features
- **Concurrency**: Handles multiple client connections concurrently using a thread pool.
- **Redis Integration**: Utilizes Redis for storing and retrieving data.
- **Handshake Protocol**: Establishes secure connections between clients and the server.
- **Command Queue**: Manages commands from clients and executes them efficiently.
- **Logging**: Captures important events and errors for debugging and monitoring.

## Getting Started
### Prerequisites
- **C Compiler**: A C compiler (e.g., GCC) is required to build the project.
- **Redis**: Redis must be installed and running on the system.
- **Thread Pool Library**: A thread pool library is required for concurrency.

### Installation
1. Clone the repository: `git clone https://github.com/botirk38/fastkey.git`
2. Build the project: `make`
3. Start the server: `./fastkey`

## Usage
### Basic Examples
- Connect to the server using a Redis client.
- Execute commands to store and retrieve data.

### Common Use Cases
- **Data Storage**: Use Fastkey to store and retrieve large amounts of data.
- **Real-time Analytics**: Utilize Fastkey's concurrency and Redis integration for real-time analytics.

## Architecture Overview
The Fastkey project consists of several components:
- **Server**: Handles client connections and manages the command queue.
- **Client Handler**: Establishes secure connections with clients using the handshake protocol.
- **Command Queue**: Executes commands from clients efficiently.
- **Redis Store**: Utilizes Redis for storing and retrieving data.
- **Logger**: Captures important events and errors for debugging and monitoring.
- **Thread Pool**: Manages concurrency using a thread pool.

## Configuration
- **Redis Connection**: Configure the Redis connection settings in the `config.h` file.
- **Thread Pool Size**: Adjust the thread pool size in the `thread_pool.h` file.

## Contributing Guidelines
1. Fork the repository.
2. Create a new branch for your feature or bug fix.
3. Commit your changes with a descriptive message.
4. Open a pull request.

## License
Fastkey is licensed under the [MIT License](LICENSE).

## Dependencies
- **C Compiler**: A C compiler (e.g., GCC) is required to build the project.
- **Redis**: Redis must be installed and running on the system.
- **Thread Pool Library**: A thread pool library is required for concurrency.

## Troubleshooting
- Check the logger output for errors and debugging information.
- Verify that Redis is installed and running correctly.
- Adjust the thread pool size and Redis connection settings as needed.

## Future Development
- **Improved Concurrency**: Enhance the thread pool implementation for better concurrency.
- **Additional Features**: Add support for more Redis commands and features.
- **Error Handling**: Improve error handling and logging for better debugging and monitoring.