I am thinking of using MEF to manage the fluent interface on Castle Windsor. Allowing for me to swap out different sections of the system for test and production. Has anyone done this if so how well did it work for you?
It's true, MEF can be made to act like a DI container but only for simple scenarios. From my experience and based on research I've done MEF's and IoC containers ideal roles might be:
- define third-party extension points using MEF
- locate and load these extensions using MEF
- structure and manage the host application’s fixed architecture using an IoC container