Implementing the Event Store
Explore how to implement an event store in Golang by building on the AggregateRepository and AggregateStore interfaces. Understand how to use PostgreSQL for event storage with optimistic concurrency control, update module components, and prepare repositories to support complex queries through CQRS. This lesson equips you to manage event sourcing effectively while addressing infrastructure and query limitations.
The AggregateRepository interface sits on top of an AggregateStore, which exists only as an interface.
The AggregateStore interface would be what finally makes the connection with the infrastructure on the other side. We will use this interface to create an event store that works with PostgreSQL. ...