Skip to content
CAI
Software that uses CAICheck a score

pholactery/eventsourcing

56.1

Adequate · 20 September 2026

612

lines of production code

Rust

primary language

4

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This is a Rust library for implementing event sourcing, providing derive macros to automatically generate event and dispatcher traits for aggregates. It supports persisting domain events through an abstraction layer that includes an in-memory store for testing and a client for the Event Store Inc. remote service. The system also handles serialization of events into the CloudEvents v1.0 specification for interoperability.

Features

Add CloudEvents v1.0 support for event serialization

The library now includes a \CloudEvent\ struct that conforms to the CloudEvents v1.0 specification, allowing internal events to be converted into a standardized JSON format for interoperability. This feature is gated behind the \eventstore\ feature flag and exposes the \CloudEvent\ type via the prelude when enabled, enabling users to serialize their domain events for external consumption or integration with CloudEvents-aware systems.

src · high confidence

Added bank and location event-sourcing examples

The examples directory now includes two sample applications demonstrating the event-sourcing library: a bank account example (bank.rs) that models deposit and withdrawal commands, and a location tracking example (location.rs) that demonstrates updating geographic coordinates. Both examples utilize the MemoryEventStore for persistence and illustrate the core Aggregate pattern by defining specific events, commands, and state transitions.

examples · high confidence

Added combat example demonstrating event sourcing with an event store

A new combat example has been added to the examples directory, illustrating how to use the eventsourcing library. It defines a domain model with combat commands and events, implements an aggregate, and uses a dispatcher to handle commands against an OrgEventStore instance.

examples/combat · high confidence

Initial release of derive macros for Event and Dispatcher traits

This change introduces the \eventsourcing-derive\ crate, providing procedural macros to automatically implement the \Event\ and \Dispatcher\ traits. The \\#\[derive(Event)\]\ macro allows enums to be used as event types, generating implementations for \event\_type\, \event\_type\_version\, and \event\_source\, and includes conditional support for converting from CloudEvents when the \orgeventstore\ feature is enabled. The \\#\[derive(Dispatcher)\]\ macro simplifies command handling by inferring associated types (Aggregate, Event, Command, State) from the specified aggregate and generating the dispatch logic that submits resulting events to the event store.

eventsourcing-derive/src · high confidence

Introduction of Event Store abstraction with in-memory and Event Store Inc. implementations

Users can now persist domain events using a new \EventStore\ trait, available via the \eventstore\ feature flag. This includes a \MemoryEventStore\ for testing and demonstration, and an \OrgEventStore\ client that connects to a remote Event Store Inc. instance (defaulting to localhost:2113) to append events as CloudEvents. The \orgeventstore\ implementation is gated by a separate \orgeventstore\ feature flag.

src/eventstore · high confidence

Test coverage

Added tests for CloudEvents serialization and deserialization

Added a new integration test file \tests/cloudevents.rs\ that verifies the round-trip conversion of CloudEvents (spec 0.1). The test ensures that a \TestEvent\ can be serialized into a CloudEvent, deserialized back, and correctly converted into the original event type, preserving all data fields.

tests · high confidence

Dependencies

Initial release of eventsourcing library and derive macros

This change introduces the initial version of the eventsourcing library (v0.1.5) and its associated derive macro crate (v0.1.3). It establishes the core dependencies for event sourcing functionality, including serde, chrono, and uuid, while adding optional support for HTTP-based event storage via reqwest. The release also defines a workspace structure and includes example applications (combat, bank, location) that demonstrate the library's capabilities.

(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 54 → 56 (+2.2)
  • Rubric changed (rubric-2026.08.17 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 100 → 99 (-0.9)
  • Architecture 100 → 100 (+0.0)
  • Maturity 54 → 54 (+0.0)
  • Readiness 26 → 36 (+10.4)
  • Security 100 → 82 (-18.0)
  • Domain Modelling 100 → 100 (+0.0)

Resolved (6)

  • Coverage not included — suite not readable by the collector
  • Dependency hygiene not measured — no supported dependency manifest was read
  • No exposed public API
  • Test reliability not included
  • early-stage repository — too few commits for a meaningful bus factor
  • early-stage repository — too little history to judge knowledge freshness

New (29)

  • Critical CVE: [GHSA redacted] (Cargo.lock)
  • Documentation: no installation or build instructions (README.md)
  • Documentation: no usage examples (README.md)
  • High CVE: [GHSA redacted] (Cargo.lock)
  • High CVE: [GHSA redacted] (Cargo.lock)
  • High CVE: [GHSA redacted] (Cargo.lock)
  • High vulnerability: [GHSA redacted] (Cargo.lock)
  • High vulnerability: [GHSA redacted] (Cargo.lock)
  • Medium CVE: [GHSA redacted] (Cargo.lock)
  • Medium CVE: [GHSA redacted] (Cargo.lock)
  • Medium CVE: [GHSA redacted] (Cargo.lock)
  • Medium CVE: [GHSA redacted] (Cargo.lock)
  • Medium advisory (unmaintained): RUSTSEC-2020-0016 (Cargo.lock)
  • Medium advisory (unmaintained): RUSTSEC-2026-0053 (Cargo.lock)
  • Medium advisory (unsound): RUSTSEC-2020-0080 (Cargo.lock)
  • Medium advisory (unsound): RUSTSEC-2023-0005 (Cargo.lock)
  • Medium advisory (unsound): RUSTSEC-2023-0072 (Cargo.lock)
  • Medium advisory (unsound): RUSTSEC-2025-0023 (Cargo.lock)
  • Medium advisory (unsound): RUSTSEC-2026-0097 (Cargo.lock)
  • Medium advisory (unsound): RUSTSEC-2026-0190 (Cargo.lock)
  • …and 9 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

pholactery/eventsourcing 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 20 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 31c1f9d5589ede0fd0e98f4a7665b85a53ca7962 — 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-28e75b8e3254.