Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using MEF with NHibernate and Castle Windsor

I have an ASP.Net MVC application that is using NHibernate under the covers for data access. I'm using the Windsor container to handle injecting ISession references into each controller.

This works great, but now I'm looking to expand my application with a pluggable architecture so that I can have a core product and specific add-ons. I found a great article on doing this with MEF.

My question is how to make the Windsor container and MEF container, life/work together so that I can achieve this. There was an article by Glenn Block that talked about this exact issue. Then end then said that the next article would show you how to do this, but there's no part 2.

Has anyone created an application like this using ASP.Net MVC, MEF, NHibernate and Castle Windsor?

like image 505
Fran Avatar asked May 21 '10 18:05

Fran


1 Answers

I have spiked small prototype of Windsor->Mef integration 6 months ago here. It is targetting the scenario you seem to be implementing, where you bootstrap your application with Windsor, and want to use MEF for extensibility. You can check it out, perhaps it'll give you some ideas

like image 138
Krzysztof Kozmic Avatar answered Oct 01 '22 03:10

Krzysztof Kozmic