martinsumner/leveled
75.8
Strong · 23 September 2026
36.8k
lines of production code
Erlang
primary language
5
measurements over time
What this system is
Leveled is an Erlang-based LSM-tree key-value store designed to serve as a backend for systems like Riak, optimized for handling large values and frequent iteration. It provides core storage capabilities including journal persistence, ledger management, and constant database storage, with support for data compression and dynamic query filtering. The system includes configuration schemas for multi-backend integration and is validated through comprehensive end-to-end and property-based tests covering CRUD operations, compaction, and data recovery.
Features
Add leveled.hrl with configurable defaults and shared records
The include/leveled.hrl file has been added, establishing the shared records and configurable startup defaults for the leveled storage system. This includes definitions for file paths (journal, ledger), cache sizing limits, compression settings (defaulting to lz4), snapshot timeouts, and various object tags (standard, index, head-only, tombstone). It also introduces shared records such as 'level' and 'cdb\_options' used across the system components.
include · high confidence
Initial project setup with build configuration and documentation
The repository is initialized with a new .gitignore file to exclude build artifacts and test data, and a rebar.config file that defines the project structure, dependencies (lz4, zstd, eqwalizer\_support), and build profiles. The README.md is updated to provide a comprehensive introduction to Leveled as an Erlang Key-Value Store, detailing its features such as HEAD request support, object tagging, and compatibility with various OTP versions.
(repo-wide) · high confidence
Initial release of Leveled LSM-tree key-value store
Introduces the core Leveled storage engine, an LSM-tree based key-value store designed for large values and frequent iterator usage, typically as a Riak backend. The release includes the main Bookie API for data operations, the Inker for journal persistence, the Penciller for ledger management, and the CDB file clerk for constant database storage. It also adds a new eval and filter expression engine (with lexer/parser) for dynamic data transformation and querying, alongside support for LZ4 and ZSTD compression, tiny bloom filters, and configurable ledger value versions.
src · high confidence
New configuration schemas for Leveled and Multi-Backend storage
Added \priv/leveled.schema\ and \priv/leveled\_multi.schema\ files that define the configuration options for the Leveled storage backend and its multi-backend integration. These schemas expose settings for data storage paths, disk flush strategies, in-memory cache sizes, and compression methods (including ZSTD support). They also provide granular control over journal management (size and object count limits), compaction scheduling (runs per day, scoring, and time windows), and snapshot timeouts for index queries.
priv · high confidence
Test coverage
Added end-to-end Common Test suites for core storage operations; Added property-based tests for codec, evaluation, filter, and set operation languages.
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
This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings — which rule fired, in which file, on which line, and how to fix it — are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.
Score
- CAI 66 → 76 (+10.3)
- Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.
Lenses
- Code Health 87 → 90 (+2.5)
- Architecture 100 → 100 (+0.0)
- Maturity 55 → 75 (+20.5)
- Readiness 62 → 66 (+4.0)
- Security 85 → 100 (+14.7)
Resolved (19)
- Coverage not included — suite not readable by the collector
- Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
- High: security finding (details withheld)
- High: security finding (details withheld)
- No exposed public API
- Off-boarding risk: anonymized user #1
- Test reliability not included
- The README is thin on concrete usage examples (e.g. how to start Leveled with options, or run tests). (docs/README.md)
- TooManyMethods: leveled_bookie (src/leveled_bookie.erl)
- TooManyMethods: leveled_cdb (src/leveled_cdb.erl)
- TooManyMethods: leveled_codec (src/leveled_codec.erl)
- TooManyMethods: leveled_iclerk (src/leveled_iclerk.erl)
- TooManyMethods: leveled_inker (src/leveled_inker.erl)
- TooManyMethods: leveled_penciller (src/leveled_penciller.erl)
- TooManyMethods: leveled_pmanifest (src/leveled_pmanifest.erl)
- TooManyMethods: leveled_sst (src/leveled_sst.erl)
- TooManyMethods: leveled_tictac (src/leveled_tictac.erl)
- TooManyMethods: leveled_tree (src/leveled_tree.erl)
- complexity unreadable for .erl, .hrl — churn × complexity hotspots could not be measured
New (66)
- 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
- Documentation: no installation or build instructions (README.md)
- Documentation: no project overview
- Documentation: no usage examples (README.md)
- Duplicated block (10 lines × 2) (src/leveled_bookie.erl)
- Duplicated block (11 lines × 2) (src/leveled_sst.erl)
- Duplicated block (11 lines × 2) (src/leveled_sstblock.erl)
- Duplicated block (11–12 lines × 2) (src/leveled_sst.erl)
- Duplicated block (12 lines × 2) (src/leveled_cdb.erl)
- Duplicated block (12 lines × 2) (src/leveled_sst.erl)
- Duplicated block (12–14 lines × 2) (src/leveled_inker.erl)
- Duplicated block (13 lines × 2) (src/leveled_cdb.erl)
- Duplicated block (14 lines × 2) (src/leveled_cdb.erl)
- Duplicated block (15 lines × 2) (src/leveled_pmanifest.erl)
- Duplicated block (16 lines × 2) (src/leveled_eval.erl)
- Duplicated block (16 lines × 2) (src/leveled_sst.erl)
- Duplicated block (1–5 lines × 7) (src/leveled_sstblock.erl)
- …and 46 more
Changes since last survey
- 22 commits — 21 feature/other, 1 fixes
By area
- (repo) — 7 commits
- src/leveled_codec.erl — 6 commits
- test/property — 4 commits
- include/leveled.hrl — 1 commit
- src/leveled_bookie.erl — 1 commit
- src/leveled_cdb.erl — 1 commit
- src/leveled_pmanifest.erl — 1 commit
- src/leveled_tree.erl — 1 commit
Notable commits
- fix: Fix the creation of data and better failure printing
- change: Clarify type on hash
- change: Clarify types following review
- change: Comment typos
- change: Generate the binaries from a grammar (as reference for futire changes)
- change: Maybe push ledger cache when SQN changes beyond threshold (#498)
- change: Merge branch 'develop-3.4' into mas-d34-i477-binaryledgervalue
- change: Merge branch 'develop-3.4' into mas-d34-i494-standardtree
- change: Merge branch 'mas-d34-i477-binaryledgervalue' of https://github.com/martinsumner/leveled into mas-d34-i477-binaryledgervalue
- change: Merge pull request #491 from martinsumner/mas-d34-i477-binaryledgervalue
- change: Merge pull request #493 from martinsumner/mas-d34-i492-map
- change: Merge pull request #495 from martinsumner/mas-d34-i494-standardtree
- change: Merge remote-tracking branch 'quviq/mas-d34-i477-binaryledgervalue' into mas-d34-i477-binaryledgervalue
- change: On cdb_roll and delete_pending (#490)
- change: Reduce test scope to more liberal decoding
- change: Remove unused function from export list
- change: Some more exports for test
- change: Support variable length metadata
- change: Type deduplication
- change: Update src/leveled_codec.erl
- …and 2 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
martinsumner/leveled 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 51abe4601155c38da091e15d0e5d4ad19ba71195 — 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.