Event Based Architecture: What do you mean by EVENT?

preview_player
Показать описание
The term "Event" is really overloaded. There are many different utilities that leverage events. Event Sourcing, Event Carried State Transfer, and Event Notifications. None of these are for the same purpose. When talking about an Event Based architecture, realize which one you're using and for what purpose.

💥 Join this channel to get access to source code & demos!

🔥 Don't have the JOIN button? Support me on Patreon!

0:00 Intro
1:10 Event Sourcing
3:03 Event Carried State Transfer
5:38 Event Notifications
8:32 Differences
Рекомендации по теме
Комментарии
Автор

I love your videos! I watch them since about 2 years. Some videos i rewatch multiple times, and they get better and better each time i view them, because i digged deeper into that matter.

RaveKev
Автор

I have been working with event oriented architrctures for almost 10 years, and this is maybe the best explanation of the missconceptions og events i have ever seen. Great Video!

t
Автор

Thank you for that great explainer video, I was always confused between Event and Event Notification.

jeet.prakash
Автор

Event Carried State Transfer: pass-by-value

Event notification: pass-by-reference

adambickford
Автор

Thank you for all your videos. You are very good at explaining it. I have always been interested in patterns, but never really known when to use them. Currently, I'm working as the only developer building an E-commer/CRM/ERP for a company - a big task for one developer, I know. It started with the Mediator + CQRS patterns. Learned a lot while researching and experimenting in my own projects. Earlier I had been into the service pattern, but that alone has some limitations. It is a lot easier for everybody involved to reason about a project in terms of commands, queries and events.

marna_li
Автор

Hi Derek, Awesome video! For event carried state transfer, let's say a couple of services need to store some data about customers, but one of the services are down for some reason and missed customer related events for a while. What would be a good way to make sure it gets back in sync when it comes back up? (assuming event sourcing is not being used)
Thanks for your content!

fredimachadonet
Автор

Concise and great explanation. Subbed :)

lchl
Автор

Thanks for the great video.
I belive in Azure they call Events with state - Messages. And Events for notifications - Events.
Also they said that Message is something that must be processed by consumer. Which actually looks like a Command :)
Can we say that Events with state are Messages?

I know that both Event and Command are Messages.
But I faced Azure confusing terminology.
What do you think about it?

alexanderbikk
Автор

Here I am again, a year later, at a new firm and project. It still seems like Event Based Architectures are not used to its full potential, just sending messages between service. I see a value, when modelling and dealing with complexity, in expressing behavior in code as Events (and Commands), but many still feel comfortable seeing code as services with methods invoking methods in a chain of methods. This still the preferred pattern, and then they complain about complexity being to complicated to manage. I try to be empathetic towards them. I was in this stage as well before dicovering DDD and Event based architecture. I think that journey was what re-kindled my interest for software development - and not just programming. Too bad these skills are not looked for in our otherwise stressful environments.

marna_li
Автор

ello.In carried transfer state, how would me managed changing of the state that is beeing transferred?I am thing that the event data is a serialisble dto that might change in time.How will we deal with.? And the second one, a log of events is feasable, in this case, Could help us?Thank you!

thedacian
Автор

Hi Derek! Imagine i push some changes / new functionality to a boundary, and that boundary now needs a local cache copy of data from another boundary. It will now receive data from that point on and forward, but what if it needs past data aswell? -- Does that indicate a bad design choice, or is there a common practice on how to seed the local cache?

MrBa
Автор

Why someone would prefer event as notification over event carried state transfer. Is event carried state transfer not event notification + state. So, do you see any issues if events used for notification also carrying state information or is it more about intent of events.

ravipandey
Автор

In my own app, in the Inventory context, I ended up creating a ProductQuantityUpdatedEvent containing the ProductId, QuantityAtHand, QuantityReserved, and QuantityAvailable. My thought was to avoid that the dependant domain is making unnecessary requests back for small amounts of data. And the receiver is probably interested in all those fields anyway. The ambition is to keep state transfer at a minimum. Sending just Ids for the most part.

marna_li
Автор

Hey Codeopinion, another masterpiece.. topics you cover are best in class...

Just wanted to know how to make data consistency in event carried state transfer.. these are mainly master data... Like product, customer
Waiting for a video on how sku will be generated in ui between services and data consistency in case of event carried state transfer....

srik
Автор

Thank you for this video. I am actually in the middle of my end of curriculum's project, and having issues to figure out how to deal with distributed transactions, most notably when it comes to rolling back in case of a potential error or something of this sort. I was wondering if using events only is enough, or do i need some sort of a workflow engine?

omarbouaouina
Автор

celerity is your strong point ....thanks mate

ebrahimmansur
Автор

What's the general strategy when you want to perform both business logic AND background tasks/side effects (such as sending emails, notifying websockets etc.) in response to the SAME event, within the same microservice? Would your handler have to perform business logic and also enqueue relevant background tasks, or is there a way to fan out the same event to different handlers within a microservice? Having to enqueue each background task manually seems like coupling, i.e. adding more side effects would mean you have to keep modifying your main business logic handler. Hope this makes sense...

jordanwalker