Blog Post

.NET 4.5: Oleg Lvovitch and Kevin Ransom - Managed Extensibility Framework (MEF) 2.0

Download this episode

Download Video


The Managed Extensibility Framework (or MEF for short) simplifies the creation of extensible applications. MEF offers discovery and composition capabilities that you can leverage to load application extensions. In the upcoming release of .NET 4.5, MEF will ship version 2.0. Recently, I got a chance to meet and chat with MEF developers Oleg Lvovitch and Kevin Ransom. What is MEF? What problems does MEF solve? What improvements have been made in v2.0? How are people using MEF in the real world? What changes in BCL 4.5 helped shape new features or improvements/refinement? These questions and more get answered by those who know best. Great meeting and chatting with you, Oleg and Kevin.

Great work going on in MEF world! Tune in. Enjoy.



Available formats for this video:

Actual format may change based on video formats available and browser capability.

    The Discussion

    • User profile image
      Artak Mkrtchyan

      There is a better approach than dynamic .XAP package loading (expressed by MEF 1.0) described at:

    • User profile image

      Sounds good, but I'm still missing isolation of extensions from my apps, like you have in MAF. Would be nice if we could just load extensions into own domains (or even processes), so that we could close them if needed!

    • User profile image

      MEF looks like a great tool.
      I have only some remarks ...

      If I am not mistaken I can do exactly the same things by using reflection.

      Additionally, if I will add an assembly to AssemblyCatalog from MEF there is not way to remove it from the memory. Assembly is always in the memory until the whole appdomain is unloaded (I hope that I am wrong but probably I am correct).

      In unmanaged code there is simple command for that FreeLibrary().

      There is not Assembly.Unload in .net and never will be (see below).
      According to this blog post

      Microsoft is not going to fix that in the future. So if we have a lot of components (e.g. in ORD) then that may be a problem.

    • User profile image

      i love mef and ive built a huge wpf app using it pretty much everywhere Smiley

      what's especially great is the extensibility, that's something that most frameworks really dont focus on, [why whould they? why build support for competing frameworks?] But mef is part of the larger .net framework and like mvc it feel really focused on beeing the IoC 'glue'

      i really hope this trend will continue in 4.5, cant wait to watch this Smiley

    • User profile image

      "Why aren't you making it available for native?"
      When you made the interview about the new DirectX features, I didn't hear you asking a single time why aren't they making the tools available for managed projects.
      80% of interviews on C9 today are published by one single self-admittedly biased anti-managed evangelist. Ridiculous.

    • User profile image

      Great stuff. But I'd really really appreciate a better documentation. I think this is part of reason why people didn't use the framework "correctly". It's really hard to find good documentation about it.

    • User profile image

      @polly: Aww. That hurts. I am not anti-anything!! In the context of DirectX, I'm not sure a question about a version of the DirectX 11 VS tools for managed code makes any sense at all. Why would you expect me to ask such a question? Did you not notice how many .NET interviews I released in the last few weeks? More to come, too. I guess it's fair to suggest that I not ask any questions that aren't on topic (from a programming language perspective) during .NET-based interviews. I'll try.

      In this case, what's wrong with asking MEF experts why it's hard to make a similar framework for native code? Did you listen to their answers? Seems to me it actually helped clarify why MEF works so well for managed code... I love what these guys are doing here and I'm a big fan of C# and managed code. Sorry to have offended you by asking what is in my mind a good question in context. Certainly, the interviewees weren't offended....


    • User profile image

      Oleg and Kevin are two expressive guys that are fun to watch.

    • User profile image

      MEF is dear to me, so this is great! Maybe you can do a check-in with Erik with one of the MEF devs and talk a bit about the specifics of the new features as well as the open source aspect of MEF, I'd really enjoy a run-down of the new stuff from the dev team and I'd really like to hear any comments about MEF being open source, how MEF contrib works and maybe why they don't use update the Codeplex repository any more (the publish the source as a zip, but the tfs server is not being used).

    • User profile image

      Great episode and wonderful guys. They made some issues about MEF1 really clear and I really hope to see them again before MEF2.

      MEF2 is only during it's beta stage so the release date will be great time for another interview to hear what are the latest bits inside the release.

      Also some examples with either code or whiteboard about scoping will be very helpful.

      Thank you for the great work.


    Comments closed

    Comments have been closed since this content was published more than 30 days ago, but if you'd like to send us feedback you can Contact Us.