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

Save Big on Coursera Plus. 7,000+ courses at $160 off. Limited Time Only!
Explore the concept of developing microservices with aggregates in this 50-minute Devoxx conference talk by Chris Richardson. Learn how to overcome the challenges of complex business logic and ACID transactions in microservices architecture using the aggregate pattern from Domain-Driven Design. Discover techniques for designing modular business logic, partitioning it into microservices, and leveraging eventual consistency. Gain insights into building microservices with aggregates and Spring Cloud, and understand the benefits and drawbacks of event sourcing. Delve into topics such as domain modeling, transaction scopes, data consistency between aggregates, event-driven sagas, and compensating transactions. Examine practical examples, including customer aggregate implementation and request handling in event-sourced applications.

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.