Event Sourcing
Explore event sourcing in asynchronous microservices to understand how events maintain service state, allow domain model changes, and support schema migration. Learn the roles of event queues, stores, and handlers in reconstructing state and managing snapshots within bounded contexts.
We'll cover the following...
An architecture’s focus on events can also entail other advantages.
-
The state each microservice has in its database is the result of the events it has received. The state of a microservice can be restored by resending all events it has received so far.
-
The microservice can even change its internal domain model and then process the events again to rebuild its database with the new version of the domain model. This facilitates database schema migration.
-
Thus, each microservice can have its own domain model according to the bounded context pattern, but all microservices ...