[英]Unexplainable WCF Service Timeout
Running an MVC web site that calls a WCF service. 运行一个调用WCF服务的MVC网站。
Site and service on 2 different machines. 在2台不同的机器上的站点和服务。
.NET framework 4; .NET Framework 4; IIS 7. IIS 7。
Production site is encountering a timeout when it should not. 生产站点遇到超时,该超时不该发生。 I created the simplest samples I could (simple web site that calls service method that returns "hi mom" after a delay) and was able to reproduce the problem. 我创建了最简单的示例(一个简单的网站,该网站调用在延迟后返回“ hi mom”的服务方法)并能够重现该问题。 Here is how it goes: 这是怎么回事:
So here is the pertinent config section of the client: 因此,这是客户端的相关配置部分:
<binding name="BasicHttpBinding_IService1"
closeTimeout="00:6:00"
openTimeout="00:6:00"
receiveTimeout="00:6:00"
sendTimeout="00:6:00"
allowCookies="false"
bypassProxyOnLocal="false"
hostNameComparisonMode="StrongWildcard"
maxBufferSize="2147483647"
maxBufferPoolSize="2147483647"
maxReceivedMessageSize="2147483647"
messageEncoding="Text"
textEncoding="utf-8"
transferMode="Buffered"
useDefaultWebProxy="true">
<httpRuntime executionTimeout="1200"
maxRequestLength="10240" />
<serviceBehaviors>
<behavior>
<serviceTimeouts transactionTimeout="00:6:00" />
</behavior>
</serviceBehaviors>
The same values are present on the server. 服务器上存在相同的值。 Following include things I've tried: 以下包括我尝试过的事情:
What else can I try? 我还能尝试什么?
[Edit] Moved the service to the same machine as the web app and the problem goes away. [编辑]将服务移至与Web应用程序相同的机器上,问题消失了。
这是生产环境中防火墙上的HTTP策略:最长请求时间为5分钟。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.