{"repo":"AhmedSobhy01/redis-clone","free":true,"listed":false,"github":"https://github.com/AhmedSobhy01/redis-clone","clone":"git clone https://github.com/AhmedSobhy01/redis-clone.git","description":"A lightweight Redis clone implemented in C++ that supports key-value operations and sorted sets","language":"C++","stars":16,"topics":["avl","c","clone","cpp","hashmap","hashtable","inmemory-db","redis","redis-client","redis-server"],"license":null,"category":"databases-storage","readme_excerpt":"Redis Clone A lightweight Redis server clone implemented in C++ that supports key-value operations and sorted sets. Overview 📘 This project is a simplified implementation of Redis, featuring: - In-memory key-value storage - Binary protocol for client-server communication - Support for strings, integers, and sorted sets - Command processing similar to Redis - Non-blocking I/O with event loop architecture Building 🛠️ Prerequisites - C++17 compatible compiler (g++ recommended) - Linux/Unix environment Compilation Running ▶️ Server The server listens on 0.0.0.0:8080 by default. Client Supported Commands 🧾 The server supports the following Redis-like commands: Basic Commands - GET key - Get the value of a key - SET key value - Set key to value - DEL key - Delete key - KEYS - Get all keys - PTTL key - Get the time to live for a key in milliseconds - PEXPIRE key milliseconds - Set a key's time-to-live in milliseconds Sorted Set Commands - ZADD key score member - Add member to a sorted set - ZREM key member - Remove member from a sorted set - ZSCORE key member - Get the score of a member in a sorted set - ZQUERY key min max - Query members within a score range Usage Examples Protocol Details 📡 Request Format Where: - msglen: Total message length (excluding the 4 bytes for msglen itself) - nargs: Number of arguments - arglenX: Length of argument X - argX: Byte data for argument X Response Format Where: - msglen: Total message length (excluding the 4 bytes for msglen itself) - tag:","default_branch":null,"files":null,"tree":[],"storefront":"/r/AhmedSobhy01","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/AhmedSobhy01/redis-clone/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}