Skip to content

shikhr/TinyDB

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TinyDB | C++ File-Based DBMS

TinyDB Setup

TinyDB is a simple file-based RDBMS in C++, inspired by SQLite and PostgreSQL. It uses a single file to store data and supports basic SQL commands.

Build & Run

mkdir build && cd build
cmake ..
make
./bin/tinydb

Tests

cd build
cmake ..
make
ctest

Roadmap

Phase 1: Core Storage Engine

  • Project Setup: Configure CMake, Git, and Google Test.
  • Disk Manager: Handles low-level, page-based file I/O.
  • Page & Buffer Pool Manager: Manages caching of disk pages in memory.

Phase 2: Data & Execution Layer

  • System Catalog: Manages metadata about tables and schemas.
  • Table Heap & Record Manager: Implements storage for unordered rows on pages.
  • SQL Parser: Translates SQL strings into an Abstract Syntax Tree (AST).
  • Execution Engine: Executes queries using a sequential scan plan.

Phase 3: Indexing & Advanced Queries

  • B+ Tree Index: A generic B+ Tree implementation for indexing.
  • Index Manager: Integrates B+ Trees as secondary indexes.
  • Query Optimizer: A basic optimizer to choose between table scans and index scans.
  • Advanced Executors: Support for UPDATE, DELETE, and WHERE clauses.

Phase 4: Concurrency & Recovery (Future Goals)

  • Transaction Manager: Manages ACID properties for transactions.
  • Lock Manager: Provides concurrency control using locking.
  • Log Manager: Implements Write-Ahead Logging (WAL) for recovery.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published