A practical example of Event Sourcing and CQRS patterns applied to a minimalistic banking domain.
Event Sourcing and CQRS Examples is a Java-based demonstration project that implements Event Sourcing and Command Query Responsibility Segregation patterns in a minimalistic banking context. It provides a working codebase to understand how these architectural patterns handle state changes as immutable events and separate read and write models. The project solves the problem of learning these complex patterns through abstract documentation by offering a concrete, runnable example.
Software architects and backend developers who want to understand or implement Event Sourcing and CQRS patterns in their applications. It's particularly useful for those working on systems requiring audit trails, temporal queries, or complex domain logic.
Developers choose this project because it provides a complete, working example rather than just theoretical explanations. It demonstrates practical considerations like idempotent event replay, event ordering, and how to combine DDD with REST, which are often glossed over in conceptual discussions.
Event Sourcing and CQRS in practice.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Provides a complete, runnable Java codebase for Event Sourcing and CQRS, demonstrating patterns like idempotent event replay and explicit ordering in a banking context.
Ensures safe event replay by assigning values instead of executing business logic, as shown with deposit events where balance is directly assigned.
Uses event versioning for optimistic locking and handling out-of-order events in distributed scenarios, addressing real-world concurrency issues.
Demonstrates how Domain-Driven Design can be combined with RESTful APIs using Ports and Adapters, debunking myths of incompatibility.
Omits critical production aspects like advanced error handling, scalability mechanisms, and REST hypermedia controls, as admitted in the README.
Requires familiarity with Event Sourcing and CQRS concepts, and setup with Java 14 and Maven, making it less accessible for beginners.
Deviates from strict CQRS by allowing some queries in the domain model, which may confuse users seeking textbook separation of reads and writes.