Summary

Get a summary of what we have covered in this chapter

We'll cover the following

Recap

We covered a lot about event sourcing, interfaces, structs, and types used to create an event sourcing implementation in Go. We started off by making a pretty big change to the simple events model used in the previous chapter. This was followed by updates to the aggregate model and an entirely new package.

We also learned about a type of registry for recallable data structures and how it is implemented and used. Refactoring for event handlers was introduced, which shaved a good number of lines from the repository, which is always a good thing.

Introducing CQRS and implementing read models could not be avoided, but working through it and implementing it revealed it to not be such a confusing or complicated pattern, thanks in part to the work from the previous chapter, of course.

We closed out the chapter by implementing snapshots in the application and covered why and when we would use them in our own applications.

Get hands-on with 1400+ tech skills courses.