#+TITLE: Relational NT
#+ATTR_ORG: :width 320
[[file:images/logo.png]]
* About
Relational NT is an experimental database kernel inspired by the object-management model of the Windows NT kernel. The project explores what database internals look like when relations, tuples, transactions, namespaces, permissions, cursors, and handles are treated as explicit runtime-managed objects.
The goal is to build a small, understandable runtime where database state is accessed through uniform paths, guarded by explicit security checks, and managed through visible lifecycle rules. The codebase is still early, so several classes define architectural boundaries before they define complete behavior.
* Design Direction
- Object management: database objects are registered, located, and referenced through a central registry.
- Permissions: access checks are kept separate from object lookup so security policy can evolve independently.
- Identity and lifecycle: opening, closing, monitoring, pinning, cleanup, and contention are modeled as runtime responsibilities.
- Handles: authorized access is explicit, which makes ownership, accounting, and cleanup visible.
- Cursors and VM: retrieval is designed around pull-based cursors and a split between terminating first-order logic and higher-order logic execution.
* Current Status
The project is currently focused on the runtime shape. Many components are intentionally skeletal while the core abstractions settle, but the headers document the intended responsibilities and constraints of each manager.
* Building
The repository includes a Visual Studio makefile project and a root =Makefile=. On Windows, build with the Visual Studio/NMake environment available:
#+begin_src shell
nmake /f Makefile windows
#+end_src
For Unix-like environments with a C++17 compiler and Make installed:
#+begin_src shell
make unix
#+end_src
* Documentation
API documentation is generated with Doxygen. The root =Doxyfile= reads the public headers, source files, and the documentation main page in =docs/mainpage.dox=.
#+begin_src shell
doxygen Doxyfile
#+end_src
Generated HTML is written to =docs/generated/html=.
The comments in the public headers are part of the design record. Keep architectural notes close to the declarations they explain so Doxygen can publish them with the API reference.
The repository also includes a GitHub Actions workflow that publishes the generated Doxygen HTML to GitHub Pages on pushes to =master=. In the repository settings, configure Pages to use =GitHub Actions= as its source.