简体   繁体   English

在 4.6.2 框架中部署 .NET 标准程序集(Microsoft.AspNetCore.SignalR.Client)

[英]Deployment of .NET Standard assembly (Microsoft.AspNetCore.SignalR.Client) in 4.6.2 Framework

There does not seem to be any particular guidance on what needs to be deployed when consuming a .net standard 2.0 package into the 4.6.2 framework build.关于在 4.6.2 框架构建中使用 .net 标准 2.0 package 时需要部署什么似乎没有任何特定的指导。

We have a large 4.6.2 project that has one assembly using Microsoft.AspNetCore.SignalR.Client via nuget package.我们有一个大型 4.6.2 项目,它有一个使用 Microsoft.AspNetCore.SignalR.Client 的程序集,通过 nuget package。 This ends up bringing in netstandard 2.0 and it's huge pile of assemblies to our output folder (100+ assemblies) but the automatic binding redirects written to the config file only list about 64 of them.这最终带来了 netstandard 2.0 和大量程序集到我们的 output 文件夹(100 多个程序集),但写入配置文件的自动绑定重定向仅列出了其中的 64 个。

My question is do I only need to deploy the ones listed in the.config file tagged with bindingRedirect or do you just deploy all of the extra "shim" assemblies?我的问题是我只需要部署标记为 bindingRedirect 的 .config 文件中列出的那些,还是只部署所有额外的“shim”程序集?

The solution for me was to build my project with SignalR using the 4.6.2 framework, you must use Package Reference for the SignalR nuget package and you must use Project Settings | The solution for me was to build my project with SignalR using the 4.6.2 framework, you must use Package Reference for the SignalR nuget package and you must use Project Settings | Auto-Generate Binding Redirects.自动生成绑定重定向。 Your output directory will contain the binding redirects needed to run the application.您的 output 目录将包含运行应用程序所需的绑定重定向。 The *.exe.config will have the redirects written out for you (that's nice) but you will find that almost the entire framework gets redirected, feels more like an in-place upgrade using binding redirects. *.exe.config 将为您写出重定向(这很好),但您会发现几乎整个框架都被重定向,感觉更像是使用绑定重定向的就地升级。 The code is in production and working well.该代码正在生产中并且运行良好。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 UWP 和 Microsoft.AspNetCore.SignalR.Client Release 配置问题 - UWP and Microsoft.AspNetCore.SignalR.Client Release configuration problem FileLoadException:无法加载文件或程序集'Microsoft.AspNetCore.SignalR.Core - FileLoadException: Could not load file or assembly 'Microsoft.AspNetCore.SignalR.Core ASP.NET 框架 4.6.2 SignalR 和 Redis 背板未连接 - ASP.NET Framework 4.6.2 SignalR and Redis backplane not connecting 使用.Net Framework 4.6.2在PC上运行.Net Standard 2.0应用程序 - Running a .Net Standard 2.0 Application on a PC with .Net Framework 4.6.2 .Net Standard 2.1 项目中 Microsoft .AspNetCore 3.1 包的问题 - Problem with the Microsoft .AspNetCore 3.1 package in a .Net Standard 2.1 project 在 .Net 标准项目中使用 Microsoft.AspNetCore.Identity? - Use Microsoft.AspNetCore.Identity in .Net Standard Project? 无法加载文件或程序集System.Xml.XPath - .Net 4.6.2引用.Net Standard 1.3 - Impossible to load file or assembly System.Xml.XPath - .Net 4.6.2 referencing .Net Standard 1.3 .Net 4.6.2项目中的.Net标准库:找不到System.Runtime程序集 - .Net Standard Library in .Net 4.6.2 project: System.Runtime assembly not found 在面向.NET 4.6.2的项目中,如何实现.NET Standard 1.5程序集中定义的接口? - In a project targeting .NET 4.6.2, how to implement an interface defined in a .NET Standard 1.5 assembly? 无法将.NET Framework 4.6.2 Web应用程序引用添加到.NET Standard任何版本 - Can not add .NET framework 4.6.2 web app reference to .NET Standard any version
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM