单独的 AppDomain 中的 C#、MAF、未处理的异常管理 [英] C#, MAF, Unhandled Exception Management in separate AppDomain
问题描述
好的,所以我有一个 MAF 应用程序,它在单独的应用程序域中加载每个插件.这非常适合我的需要,因为它允许我在运行时动态卸载和重新加载我的插件.
Okay, so I have a MAF application which loads up each addin inside of a separate appdomain. This is working fantastic for what I need as it allows me to dynamically unload and reload my addins at runtime.
问题是,我需要能够在子应用程序域中处理一个未处理的异常,捕获它,然后让该应用程序域优雅地失败而不取消父应用程序域
The problem is, I need to be able to take an unhandled exception in the child appdomain, catch it, and then let that appdomain fail gracefully without taking down the parent appdomain
我该怎么做?这似乎是一项微不足道的任务,也是使用独立应用程序域的主要好处之一...
How do I go about doing this? It seems like a trivial task and one of the main benefits of using isolated appdomains...
推荐答案
我认为我对这个类似问题的回答应该对您有所帮助:
I think my answer to this similar question should help you:
如果您需要更多信息,请告诉我.
Let me know if you need any more information.
这篇关于单独的 AppDomain 中的 C#、MAF、未处理的异常管理的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!