Life Beyond Distributed Transactions: An Apostate's Implementation - Dispatching Example

Posts in this series: A Primer Document Coordination Document Example Dispatching Example Failures and Retries Failure Recovery Sagas Sample code from this series In the last post, we looked at refactoring our documents to use messaging to communicate changes. We're still missing something, however - the dispatcher: Our dispatcher is the main component that facilitates document communication. For a given document, it needs to: Read messages out of a document's [Read More]

Life Beyond Distributed Transactions: An Apostate's Implementation - Document Example

Posts in this series: A Primer Document Coordination Document Example Dispatching Example Failures and Retries Failure Recovery Sagas Sample code from this series In the last post, I walked through the "happy path" scenario of coordinated communication/activities between multiple resources that otherwise can't participate in a transaction. In this post, I'll walk through a code example of building out document coordination in Azure Cosmos DB. My starting point is [Read More]

Life Beyond Distributed Transactions: An Apostate's Implementation - Document Coordination

Posts in this series: A Primer Document Coordination Document Example Dispatching Example Failures and Retries Failure Recovery Sagas Sample code from this series Quick note - I've updated this post to use the more accurate term "Document" than the less-accurate, DDD-specific term "Aggregate". In the images, it still has the older term "Aggregate", let's pretend I fixed all those images. In the last post, I walked through the general problem [Read More]

Life Beyond Distributed Transactions: An Apostate's Implementation - A Primer

Posts in this series: A Primer Document Coordination Document Example Dispatching Example Failures and Retries Failure Recovery Sagas Sample code from this series For those working with SQL databases, working with transactions is more or less a given. The most we may need to worry about is: Using the appropriate isolation level Not doing too much in a single transaction to prevent excessive locks The vast majority of applications I [Read More]

Vertical Slice Architecture

Many years back, we started on a new, long term project, and to start off with, we built the architecture around an onion architecture. Within a couple of months, the cracks started to show around this style and we moved away from that architecture and towards CQRS (before it had that name). Along with moving to CQRS, we started building our architectures around vertical slices instead of layers (whether flat [Read More]