防止在 wsp 解决方案卸载/撤销期间删除共享 dll

发布于 2024-09-28 05:36:46 字数 234 浏览 0 评论 0原文

我正在开发一系列使用来自 Telerik 等供应商的第三方 DLL 的解决方案。我们在您的大多数解决方案中都使用该 dll。但是当我卸载任何解决方案时,dll 就会从程序集中删除。这是一种非常不幸的行为。

我想即使将 dll 放在 bin 文件夹中也无济于事。因为我可以在同一个 Web 应用程序中使用多个解决方案。在这种情况下,如果我删除解决方案,它也会从 bin 文件夹中删除 dll。

这个丑陋问题的解决方法是什么?

I'm working on a bunch of solutions which uses a third party DLL from vendors like Telerik. We use the dll in most of your solutions. But when i uninstall any of the solutions the dll is getting removed from the assembly. This is a very unfortunate behavior.

I guess even putting the dll in the bin folder wont help it. Because i can use multiple solutions in a same web application. In that case if i remove on solution it is removing the dll from bin folder too.

What is the workaround for this ugly issue?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

十六岁半 2024-10-05 05:36:46

这确实是痛苦的。您可以考虑使用 ilmerge 合并第 3 方 DLL。其他方法可以在 Muhimbi 的免费 SharePoint 编码指南(章节8 和 9)

This is indeed painful. You could consider merging 3rd party DLLs in using ilmerge. Additional approaches can be found in Muhimbi's free SharePoint Coding Guidelines (Chapters 8 and 9)

铁憨憨 2024-10-05 05:36:46

一种选择是不在您的个人解决方案中包含第三方 DLL。当您卸载该解决方案时,随该解决方案安装的所有内容都将被删除。您可以拥有一个安装常见 DLL 的“框架”解决方案。这样,只有当您删除框架解决方案时,那些常见的 DLL 才会被删除。或者,如果您想要对每个共享 DLL 进行更细粒度的控制,您可以为每个共享 DLL 使用一个解决方案安装程序。

另请参阅 SharePoint.SE 上的问题:使用共享 dll 的多个解决方案在撤回单个解决方案时可能会造成严重破坏

One option is not to include the third party DLLs in your individual solutions. Anything that gets installed with a solution will be removed when you uninstall that solution. You can have a 'framework' solution that installs common DLLs. This way, those common DLLs are only removed if you remove your framework solution. Or you could have a single solution installer for each shared DLL if you want more fine-grained control over them.

See also the question on SharePoint.SE: Multiple solutions using shared dlls can cause havoc when individual solutions are retracted

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文