Closed martosource closed 9 years ago
No, but I'm working on it. Looking at converting the MVC sample app to using it from MS.
First: Thanks for a great series of blog posts and a simple, easy to understand Mediator.
I would love to see an example with (domain) event dispatching as well. I'm working on a similar project just to learn the pattern (https://github.com/jenspettersson/Mediocr - partly a shameless clone ;)) where I'm struggling a bit with how to track and dispatch events from domain entities.
I'm using RavenDb and for now I wrapped the session with a... generic repository... that also keeps the requested entities in it's own UoW so I can access them easily later... It doesn't feel... perfect.
Thanks Jimmy.
If you are able to set up and start the conversion of a MVC sample app, I am more than happy to put the work in to complete it.
I also could help the sample, but we do need something to follow along, so lets us know when you do have something. Another question regarding your post: http://lostechies.com/jimmybogard/2013/12/19/put-your-controllers-on-a-diet-posts-and-commands/
you said: "So why two methods? Fairly simple – it’s a bit easier to deal with separate pipelines for queries and commands, as the potential extensions for these two pipelines might be different. I also might have different rules applied and so on."
But as far as I checked mediatR, you only have one type to handle and not one for queries and other for commands. Am I wrong ? Or do you mind explaining why going in this path ?
On the queries/command thing - I just changed my mind. There wasn't any difference between the two, I could control it more easily with an ICommand or IQuery that I define.
Thanks for the feedback, I also think your line of thinking is better. It is much easier to deal with side effects than all the code necessary to keep it 100% separating between query and commands.
Hey Jimmy, any update on the MVC sample?
Does the Web API example help at all? It would work for MVC too.
I have a complete working version with OWIN + MediatR + Autofac + Web Api 2 and the basic test it went just fine.
@getuliojr if you're down for it, i'd love a PR that does something similar with what I did for StructureMap. Big ask though, I know
That works for me!
On Fri, Jan 23, 2015, 11:04 AM Jimmy Bogard notifications@github.com wrote:
Does the Web API example help at all? It would work for MVC too.
— Reply to this email directly or view it on GitHub https://github.com/jbogard/MediatR/issues/8#issuecomment-71215572.
I will prepare a PR and build an example working with this tecnology by next week ok ? Glad to help the community back.
Awesome!
Updated Web API to include an MVC sample
Hi jbogard, Thanx for your post here. You concept is good. But I am looking few steps in making an application using mediatr with my MVC EF 6 codefirst with angularjs. It will be much helpfull if you can recommend any posts or website to follow or even your guidance.
I need to know how to run your mediatr application, just was trying to achieve ResourceName method through errors.
I am trying to implement CQRS in ASP.NET MVC application But It didn't work can anyone help me how to implement CQRS in MVC.
Is there a complete example of using MediaR with ASP.NET MVC including the decorator pattern pipeline for validation, authorisation?