Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

YouTube

Developing Microservices with Aggregates

Devoxx via YouTube

Overview

Google, IBM & Meta Certificates – 40% Off
One Coursera Plus subscription covers most Professional Certificates on Coursera.
Unlock All Certificates
This course explains how domain-driven design aggregates help structure business logic for microservices and support eventual consistency. It uses a customer aggregate to illustrate event-sourced processing and discusses Sagas, event stores, and their tradeoffs.

Syllabus

Developing Microservices with Aggregates
Presentation goal
About Chris
Microservice architecture
Domain model = tangled web of classes
Reliance on ACID transactions to enforce invariants
and requires 2PC
2PC is not an option
Domain Driven Design - building blocks
About Aggregates
Aggregate: rule #1
Domain model = collection of loosely connected aggregates
Easily partition into microservices
Aggregate rule #2
Transaction scope = service
How to maintain data consistency between aggregates?
Using event-driven Sagas instead of 2PC
Saga-based, eventually consistent order processing
Complexity of compensating transactions
How atomically update database and publish an event
Failure = inconsistent system
Event sourcing = event-centric persistence
Persists events NOT current state
Replay events to recreate state
The Customer aggregate
Customer command processing
Customer applying events
Request handling in an event sourced application
Event Store publishes events consumed by other services
Event store = database + message broker
Benefits of event sourcing
Drawbacks of event
Summary

Taught by

Devoxx

Reviews

Start your review of Developing Microservices with Aggregates

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.