Blog Articles on DDD, Event Sourcing and software development in general, with a sprinkle of PHP and sarcasm.

Immediate vs eventual consistency

In the [last article]( we looked at projectors, the backbone of any CQRS/Event Driven system. This article was originally meant to be about implementing projectors, but I realised there was an important question to answer first, one that would shape the solution, "When do we project the events, now, or later?". Turns out this question has far reaching effects, so it's important we dig into it before moving onward. # Immediate vs Eventual Consistency When it comes to projectors there are two choices, immediate or eventual consistency. With i...
Read on »

Event Granularity: Modelling events in event driven applications

Interested in building an event driven application? If so there's one problem that will rear it's head pretty early; how big or small do you make your events? # Event Driven Systems Before we begin, let's give some background on Event Driven Systems. Event Driven systems don't make synchronous calls to each other, instead they broadcast messages, ie. "Events". Other services listen for these events and process them at their own speed. Say a service starts to slow down or crashes, other services will keep working as if nothing is wrong. Once the failing service is booted up again, it goes back to processing events and catches up to ...
Read on »