
Practical Event-Driven Microservices Architecture by Hugo Filipe Oliveira
About this episode
This episode explores the crucial, but often overlooked, aspect of data integrity in event-driven microservice architectures. Ensuring data remains consistent and reliable across distributed services can feel like navigating a minefield of potential pitfalls. We'll explore how to avoid those pitfalls.
Topics Covered:
● Why Concurrency Is Tricky (and How to Prevent Disaster): The shift from monolithic applications to distributed systems demands a fresh perspective on handling concurrency. Discover why traditional approaches fall short and explore practical strategies:
○Pessimistic Concurrency: Learn how techniques like database locks and distributed consensus algorithms (e.g., using tools like ZooKeeper) can prevent conflicts before they occur.
○Optimistic Concurrency: This approach, often favored for its performance benefits, relies on detecting conflicts and applying retries or compensation strategies. Understand how versioning and conditional updates play a vital role.
●Out-of-Order Messages: Taming the Chaos: In an asynchronous world, messages don't always arrive in the order you expect. We'll examine techniques to handle these situations gracefully:
○Event Versioning: Discover how assigning versions to events can help services identify and address inconsistencies caused by out-of-order processing.
○End-to-End Partitioning: By carefully routing related events to the same partitions within a message broker, you can enforce ordering and simplify concurrency management. We'll explore the benefits and potential challenges of this approach.
●Resilience Strategies: Building fault-tolerant systems is crucial in a distributed environment. We'll examine key patterns for achieving resilience:
○Idempotency: Learn how to design services that can handle the same message multiple times without creating unintended side effects. We'll discuss common patterns and how they apply to event-driven systems.
○The Outbox Pattern: Discover how this technique ensures events are published reliably, even in the face of database or network failures. We'll walk through a practical example of implementing an outbox using a dedicated database table.
Support: https://yazdipour.com/donate
Get every episode summarized
Each time Tech Book Podcast publishes, we email you a written briefing from the transcript — the topics, who appeared, and any specific claims, with the ad reads skipped.
Email me new episodesFree for 3 shows. No card needed.
Hosts & guests
No transcript yet
This episode has not been transcribed. Request it and it moves to the front of the queue.
More episodes
More from Tech Book Podcast

Site Reliability Engineering: How Google Runs Production Systems
Tech Book Podcast

Software Engineering at Google
Tech Book Podcast

Clean Architecture by Robert Cecil Martin
Tech Book Podcast

Soft Skills: The software developer's life manual
Tech Book Podcast