Course Details

CQRS and Event Sourcing

Generally speaking, any actions performed on a software system belong to one of the following two categories: query or command.

The logical separation that exists between queries and commands doesn’t show up clearly if the two groups of actions are forced to use the same domain model. For this reason, a new supporting architecture emerged in the past few years called CQRS, which is short for Command/Query Responsibility Segregation.

The CQRS pattern is based on a simple, almost commonplace, idea: queries and commands (sometimes also referred to as reads and writes) are very different things and should be treated separately.

Event sourcing (ES) goes beyond the use of domain events as a tool to model business logic. ES takes events to the next level by persisting them. In an ES scenario, your data source just consists of persisted events. You don’t likely have a classic relational data store; all you store are events, and you store them sequentially as they occur in the domain.

course
  • Introduction to CQRS and ES
  • Separating commands from queries
  • Query stack
  • Command stack
  • Domain events
  • Persisting events
  • Replaying events
  • Understand the need to separate reads and writes
  • Understand modelling domain logic as events
  • Understand how to do store events to domain domain state.
  • Understand events to provide a history of domain model state.
  • Understand aggregates to represent the current state of the application.
  • Understand calculators to update the state of the application.
  • Understanding reactors to trigger side effects as events happen
  • Weekend Class: 09.00 am - 14.00 pm
  • Midweek Class: 09.00 am - 20.00 pm