Skip to content
CAI
Software that uses CAICheck a score

mateodelnorte/sourced-repo-mongo

54.6

Adequate · 21 September 2026

323

lines of production code

JavaScript

primary language

4

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This system is a MongoDB-backed repository for event-sourced entities, providing a core abstraction for persisting and retrieving state via events and snapshots. It supports committing single or multiple entities, fetching by ID or all records, and managing event emission and snapshot loading. The implementation relies on the \sourced\ library and includes a test suite to verify entity initialization and event digestion.

Features

Initial release of the MongoDB event and snapshot repository

This change introduces the core \Repository\ class and \mongo\ connection manager for storing and retrieving event-sourced entities in MongoDB. The implementation provides methods to commit single or multiple entities (\commit\, \commitAll\), retrieve entities by ID or all entities (\get\, \getAll\), and manage snapshots and events with specific index configurations. It also includes a test suite using Mocha to verify that enqueued events are emitted after commits and that entity states are correctly persisted and retrieved.

(repo-wide) · high confidence

Test coverage

Added test suite for the MongoDB repository implementation

Added a new test suite for the MongoDB repository, including a configuration file and an index.js test file that verify entity initialization, event digestion, snapshot loading, and event emission behavior.

test · high confidence

Dependencies

Initial release of sourced-repo-mongo package

The package.json and package-lock.json are introduced, establishing the project's dependencies: debug 4.3.1, lodash 4.17.21, mongodb 3.6.9, and sourced 2.0.8, along with dev dependencies jest 27.0.4, mocha 9.0.0, and should 13.2.3.

(dependencies) · 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 51 → 55 (+3.1)
  • Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 100 → 100 (+0.0)
  • Architecture 69 → 69 (+0.0)
  • Maturity 36 → 36 (+0.0)
  • Readiness 56 → 69 (+13.1)
  • Security 75 → 71 (-4.0)

Resolved (33)

  • Coverage not included — suite not readable by the collector
  • Critical CVE: [GHSA redacted] (package-lock.json)
  • Critical CVE: [GHSA redacted] (package-lock.json)
  • Critical CVE: [GHSA redacted] (package-lock.json)
  • Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • …and 13 more

New (40)

  • Coverage not measured — JavaScript/TypeScript suite
  • Critical CVE: [GHSA redacted] (package-lock.json)
  • Critical CVE: [GHSA redacted] (package-lock.json)
  • Critical CVE: [GHSA redacted] (package-lock.json)
  • Documentation: no installation or build instructions (README.md)
  • Documentation: no project overview (README.md)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • High CVE: [GHSA redacted] (package-lock.json)
  • …and 20 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

mateodelnorte/sourced-repo-mongo 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 21 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 b74bc07332c10680a7b298197c7d44a59c86ac0e — 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-fa71c66cabd8.