brendanzab/chronicle
59.9
Adequate · 9 November 2026
521
lines of production code
Rust
primary language
7
measurements over time
What this system is
This system is an event-sourcing framework for Rust that provides core abstractions for domain modeling and event storage. It defines traits for managing aggregates and persisting events, with concrete implementations for in-memory and PostgreSQL backends. The codebase also includes example applications, such as a bank, counter, and todo list, demonstrating how to build stateful services using this pattern.
Features
Add bank example with API and domain models
The bank example now includes a structured API layer defining endpoints for account management (open, deposit, withdraw, close) and money transfers, alongside domain models for accounts and transfers that utilize UUIDs and a Money type. The example exposes a launch function to start the Rocket-based server, providing a concrete implementation of the framework's patterns.
examples/bank · high confidence
Add counter example demonstrating aggregate pattern
Added a new counter example in the examples/counter directory, implementing a simple state machine with increment, decrement, and reset commands. The example demonstrates the use of the Aggregate trait from the chronicle\_domain crate, showing how to handle commands and produce events. The implementation includes state management with bounds checking (0-100) and event application logic.
examples/counter · high confidence
Add in-memory event store implementation
Added a new \chronicle\_memory\ crate providing an in-memory implementation of the \EventStore\ trait. This allows users to store and retrieve events in memory, which is particularly useful for testing scenarios. The implementation supports concurrent access and maintains event ordering via a global offset.
_chronicle\memory · high confidence
Add todo list example API
A new todo list example is introduced, providing a REST API for managing tasks. The API exposes endpoints for creating tasks, changing descriptions, completing, and archiving tasks, all backed by an in-memory event store.
_examples/todo\list/src/api · high confidence
Add todo list example application
A new todo list example has been added to the codebase, providing a complete working application built with Rocket and Chronical. The example demonstrates how to use the event store directly and return futures from command handlers, serving as a reference implementation for users.
_examples/todo\list/src · high confidence
Add todo list example with task domain model
A new todo list example has been added to the codebase, introducing a task domain model. This includes the definition of task states, events, and commands, along with the implementation of the aggregate root logic for handling task operations such as creation, description updates, completion, and archiving.
_examples/todo\list/src/domain · high confidence
Introduce Postgres-backed event store schema
The chronicle\_postgres module now includes a new database migration and Rust models for an 'events' table. This table stores event data with fields for source ID, sequence number, payload (as binary data), and a created\_at timestamp, providing the underlying storage structure for the new Postgres event store implementation.
_chronicle\postgres · high confidence
Introduce the Chronicle event store interface and PersistedEvent model
The chronicle module now provides the core abstractions for an event-sourcing system. It defines the PersistedEvent struct, which wraps an event payload with metadata including a global offset, a source ID (UUID), and a sequence number. The module also introduces the EventStore trait, which defines the contract for appending and retrieving events, with the Offset type constrained by PartialOrd to support different storage backends. Additionally, helper methods like as\_ref and map are provided on PersistedEvent to facilitate reference access and transformation.
chronicle · high confidence
Introduces the core Aggregate trait for domain modeling
A new 'Aggregate' trait has been added to the chronicle\_domain crate, providing a generic interface for validating and applying commands. This trait defines the structure for aggregates, including state, events, commands, and error types, along with methods to handle commands and apply events. This establishes the foundational abstraction for domain logic in the application.
_chronicle\domain · high confidence
Dependencies
Introduce Chronicle event-sourcing libraries and example applications
Added new Rust crates for event sourcing: the core 'chronicle' library, a domain model crate 'chronicle\_domain', an in-memory event store 'chronicle\_memory', and a PostgreSQL-backed event store 'chronicle\_postgres' (using diesel). These are accompanied by example applications ('bank', 'counter', 'todo\_list') demonstrating their usage, with dependencies on 'futures' 0.1.10, 'uuid' 0.4.0, and 'rocket' 0.2.0.
(dependencies) · medium confidence
Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
Score
- CAI 60 → 60 (+0.0)
- Rubric changed (rubric-2026.10.5 → rubric-2026.11.2) — scores are not directly comparable.
Lenses
- Code Health 99 → 99 (+0.0)
- Architecture 100 → 100 (+0.0)
- Maturity 47 → 47 (+0.0)
- Readiness 43 → 43 (+0.0)
- Security 100 → 100 (+0.0)
- Domain Modelling 100 → 100 (+0.0)
Resolved (3)
- Inconsistent payload representation: PersistedEvent uses a typed Event struct, NewEvent uses a byte slice (&[u8]), and the Postgres Event model uses a single byte (u8). This suggests either a serialization inconsistency or a bug in the Postgres model definition.
- Offset type ambiguity: The EventStore.events method takes an Offset parameter, and PersistedEvent has an Offset property, but the Postgres Event model uses i64 for offset. It is unclear if Offset is a distinct type or an alias for i64, leading to potential conversion friction.
- Semantic mismatch in event production: EventStore.append_events accepts a single Event (singular) despite the method name implying plural events, while Aggregate.handle_command returns a future of events (plural). This creates confusion about whether the API expects batch or single event operations.
Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
brendanzab/chronicle 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 9 November 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit 75c87e6242ed9f42817e78599ee3f84ae1ff4ac7 — the exact code this score is about.
- Scored under rubric-2026.11.2 — the same rubric and the same method as every other entry in this index.
- Measured by Canine Code Analyzer (cca.canine.dev) using cca measure-2026.11.3+preprod-bb0cb800cd0f.