关于WCF

1. AspNetCompatibilityRequirements 设置这个是为了WCF走ASP.NET管线,能够获取到asp.net上下文信息。

如: HttpContext.Current

对应于这个设置,在web.config的<system.serviceModel>

中需要加上<serviceHostingEnvironment aspNetCompatibilityEnabled="true">




原文地址:https://www.cnblogs.com/lfzwenzhu/p/1966694.html