I Built My Own Database From Scratch — Meet CleaveDB
I Built My Own Database From Scratch — Meet CleaveDB I've been building something I've wanted to experiment with for a while: CleaveDB . CleaveDB is a hybrid relational-document graph database built with Python, Rust, and C++ SIMD , with its own query language, graph relationships, and built-in semantic search. The idea started with a simple question: What if relational data, documents, graphs,…
I've been working on an innovative database project called CleaveDB, an experiment in combining relational, document, graph, and semantic capabilities into a single system. CleaveDB is built using Python, Rust, and C++ with special optimizations for performance.
What sets CleaveDB apart is its unique query language, CleaveQL, which allows users to seamlessly work with relational data, documents, graphs, and semantic search. For example, users can insert data using a simple "POUR" command, and then query it using "SCOOP".
CleaveDB also supports graph-style relationships called "Bonds", enabling unlimited depth and multi-hop traversals with natural language queries. Additionally, semantic search is available, allowing for meaning-based searches rather than just keyword searches.
Under the hood, CleaveDB is not built on top of existing database engines. The storage layer is being created from scratch using Rust, with C++ SIMD optimizations for critical performance operations. The project also includes B+Tree storage, WAL and transactions, multi-tenant isolation, authentication, Python bindings, and various interfaces like HTTP, WebSocket, and TCP.
Although CleaveDB is still in a very early stage, building these components from scratch has been a fascinating learning experience. While there are already many excellent databases available, such as PostgreSQL, MongoDB, Redis, and Neo4j, CleaveDB aims to combine their best features in a new way. If you're interested in databases, Rust, storage engines, graph databases, or just curious about how a database is built from the ground up, I'd welcome your feedback and ideas.
Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.