Raising Domain Events For Multiple Subscribers

后端 未结 1 763
孤独总比滥情好
孤独总比滥情好 2021-02-11 05:41

I am stating to look into the Domain Events pattern and have read a lot of resources on the subject but I cannot find a good way of implementing for our requirements. Basically

相关标签:
1条回答
  • 2021-02-11 06:22

    I think I have an example of how to do this for you and I happen to be using MVC and AutoFac also! In my specific example I am concentrating on Command/Query separation but in doing so I had to implement a domain event pattern.

    First have a read of this blog post so you get an overview of how things hang together and what the code looks like: http://www.nootn.com.au/2013/03/command-query-separation-to-better.html

    So I would recommend installing the DotNetAppStarterKit.Web.Mvc NuGet package, then take a look at the Global.asax file for how to register all the components you will need. You can peruse the SampleMvc application for things like Event Subscribers.

    I hope this helps and gets you up and going quickly. You can just use the event publisher/subscriber parts of DotNetAppStarterKit without using commands and queries.

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