Skip to content
CAI
Software that uses CAICheck a score

krestenkrab/hanoidb

53.6

Adequate · 23 September 2026

3.8k

lines of production code

Erlang

primary language

5

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

HanoiDB is a log-structured merge tree (LSM) key/value storage engine implemented in Erlang. It provides core storage operations including configurable key expiration and concurrent data folding via worker processes. The system includes benchmarking tools and a comprehensive test suite to validate its architecture.

Features

Add header files for hanoidb and plain\_rpc modules

New header files are introduced to support the hanoidb (LSM-trees indexed storage) and plain\_rpc (RPC module) components. The hanoidb header defines a key\_range record for managing key intervals and an async fold chunk size constant. The plain\_rpc header provides macros for call, reply, and cast message structures, facilitating remote procedure call interactions.

include · high confidence

Added HanoiDB benchmark driver and visualization tools

Users can now run benchmarks against HanoiDB, an LSM-tree based storage engine, using the new basho\_bench\_driver\_hanoidb.erl module. Additionally, a shell script (visualize-hanoi.sh) is provided to monitor and visualize the state of HanoiDB data files during benchmarking.

tools · high confidence

Added design diagrams for the Hanoi project

A new file, doc/design\_diagrams.graffle, was added to the repository. This file contains design diagrams for the Hanoi project, which was previously known as lsm-btree. The diagrams provide visual representations of the system's architecture and design.

doc · high confidence

Initial release of HanoiDB, a log-structured merge tree key/value storage engine

HanoiDB is introduced as an indexed, key/value storage engine based on a log-structured merge tree (LSM-BTree) architecture. The release includes the core Erlang implementation, a Makefile for building and testing, and configuration options for compression, expiry, and merge strategies. The project is licensed under the Apache 2.0 license and includes design documentation explaining the storage mechanics.

(repo-wide) · high confidence

Behavioural changes

Introduce hanoidb storage engine with configurable expiry and concurrent folds

The hanoidb module now supports per-key and global key expiration via the \expiry\_secs\ configuration option, allowing keys to automatically expire after a specified duration. Additionally, the \open\ and \open\_link\ functions now accept a \spawn\_opt\ option to configure the process flags for the underlying gen\_server, and the \fold\ and \fold\_range\ operations are now handled by dedicated worker processes to improve concurrency and prevent blocking.

src · high confidence

Test coverage

Added test suite for hanoidb storage engine

Added new test files (hanoidb\_drv, hanoidb\_merger\_tests, hanoidb\_tests, hanoidb\_writer\_tests) that provide unit and property-based testing for the hanoidb LSM-tree implementation, including drive modules, merger logic, and writer/reader operations.

test · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 52 → 54 (+2.0)
  • Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 87 → 90 (+2.7)
  • Architecture 96 → 97 (+1.2)
  • Maturity 35 → 59 (+23.8)
  • Readiness 41 → 37 (-3.9)
  • Security 100 → 67 (-33.3)

Resolved (9)

  • Coverage not included — suite not readable by the collector
  • Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • No exposed public API
  • Test reliability not included
  • The README mentions Trifork and Basho as partners but does not link to their respective repositories or provide a one-click install guide for HanoiDB itself. (README.md)
  • The README states HanoiDB is developed by Trifork and Basho but does not mention any open-source license or repository for the source code. (README.md)
  • TooManyMethods: hanoidb_level (src/hanoidb_level.erl)
  • complexity unreadable for .erl, .hrl — churn × complexity hotspots could not be measured
  • dormant codebase — no living knowledge left to concentrate

New (31)

  • Coverage not measured — no coverage collector is wired up
  • Dependency hygiene PARTLY measured — rebar3 pinning read, dependency currency not (no rebar.lock-pinned Hex declaration to grade)
  • Documentation: no contributor guidance (README.md)
  • Documentation: no installation or build instructions (README.md)
  • Documentation: no usage examples (README.md)
  • Duplicated block (5 lines × 2) (src/hanoidb_level.erl)
  • Duplicated block (6 lines × 2) (src/hanoidb_nursery.erl)
  • Duplicated block (7 lines × 2) (src/hanoidb_merger.erl)
  • Floating source dependency: ebloom
  • Floating source dependency: lager
  • Floating source dependency: lz4
  • Floating source dependency: plain_fsm
  • Floating source dependency: sext
  • Floating source dependency: snappy
  • Floating source dependency: triq
  • No SBOM
  • No artifact signing
  • No build provenance
  • No dependency lockfile committed (rebar.config)
  • TodoComment (src/hanoidb.erl)
  • …and 11 more

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

krestenkrab/hanoidb was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 23 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 68333fa51a6fdf27834fc84f42d4421f9627e3b7 — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-955b9cee9818.