Domain driven programming and events

前端 未结 1 1097
清歌不尽
清歌不尽 2021-01-03 03:03

I\'m doing some asp.net mvc coding using DDD. I have objects representing the business entities and service repositories that handle fetching and adding them. I\'m new to th

相关标签:
1条回答
  • 2021-01-03 03:12

    Thing You might want to check out are so called domain events. Basically idea is that domain model itself triggers domain specific events (e.g. CustomerRegistered) and pretty much anything You like can subscribe to them to do additional stuff outside of domain.

    Udi Dahan wrote some nice articles on this: 1st, 2nd, 3rd.

    Also - sample application by Szymon is quite explanatory on this.

    CQRS is great, but it affects whole architecture. Might be an overkill.

    0 讨论(0)
提交回复
热议问题