Overview
The Mini Algebraic Engine (MMA) is an academic project designed to implement a lightweight relational query engine capable of evaluating relational algebra expressions from the command line. The engine supports three core operators—selection, projection, and equi-join—and executes queries on CSV datasets fully loaded in memory.
The project emphasizes key software engineering concepts, including functional programming, collections, and file I/O, while avoiding imperative evaluation strategies. Queries are expressed as execution plans in JSON format or written in a custom algebraic syntax and translated automatically.
My Contribution
I was responsible for the full design and implementation of the engine. This included defining the operator abstraction, implementing relational operators, designing the query execution model, handling JSON parsing and algebra translation, and ensuring compliance with strict build and quality requirements (tests, code coverage, and style rules).
Key Features
Relational Algebra Execution
The engine evaluates algebraic execution plans composed of SCAN, SELECT, PROJECT, and JOIN operators, producing results as CSV files.
Functional Evaluation Model
Each operator is implemented as a functional component that returns a new table without mutating its inputs, enabling clean composition and predictable execution.
Dual Query Input Support
- JSON-based execution plans representing operator trees
- Custom algebraic syntax (.alg) translated automatically into JSON plans
Robust Engineering Practices
- Built with Maven and Java 17
- Unit tests implemented with JUnit 5
- Code coverage measured using JaCoCo
- Coding standards enforced via Checkstyle
Outcome
- A fully functional relational query engine executable as a standalone JAR
- Clean functional architecture for operator composition
- Automated testing and quality enforcement integrated into the build
- A solid foundation for extending the engine with additional operators and optimizations