【发布时间】:2011-02-11 09:53:21
【问题描述】:
我收到此 TCP 错误:(10055: An operation on a socket could not be performed because the system lacked sufficient buffer space or because a queue was full) occurred while transmitting data.
如果我尝试传输任何超过 50 MB 的文件,我显然会开始收到此错误。 我正在使用 WCF。我有用 Java/Tomcat 编写的 Web 服务。
这可能是服务器端配置的问题吗?
服务器是Tomcat,你能告诉我在这种情况下要自定义哪个值吗?
<bindings>
<basicHttpBinding>
<binding name="MyWebService1SoapHttpPortBinding" closeTimeout="00:01:00"
openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:11:00"
allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"
maxBufferSize="4000000" maxReceivedMessageSize="99999999"
messageEncoding="Mtom" textEncoding="utf-8" transferMode="StreamedRequest"
useDefaultWebProxy="true">
<security mode="None">
<transport clientCredentialType="None" proxyCredentialType="None"
realm="" />
<message clientCredentialType="UserName" algorithmSuite="Default" />
</security>
</binding>
</basicHttpBinding>
</bindings>
<client>
<endpoint address="http://[IP]/Transfer"
binding="basicHttpBinding" bindingConfiguration="MyWebService1SoapHttpPortBinding"
contract="Transfer" name="MyWebService1SoapHttpPort" />
</client>
【问题讨论】:
-
你试过增加你的
maxBufferSize吗? -
我试过这个 maxBufferSize="2147483647" maxBufferPoolSize="524288" maxReceivedMessageSize="2147483647"
却无济于事。我还是觉得一定是tomcat配置问题,。好像它是 IIS 我将不得不更改大型二进制文件的 maxrequestlendth 参数 -
这是 Windows 配置/资源问题,问题不在于您的应用程序。请参阅下面的答案。