WCF 服务端经常报异常,如何处理,急急急!谢谢大家

langhua553 2017-11-13 03:11:07
各位朋友,我的程序发现一个现象,WCF服务端经常报如下错误

那个超时的两分钟:00:02:00 不知道在哪里设置的,我的客户端配置,服务端配置都改成了3分钟,这个00:02:00不知道哪里来的,不知道这个异常到底来源哪里,程序运行也好像正常,就是不知道这个异常怎么解决。

如下是配置文件
<netTcpBinding>
<binding name="NetTcpBindingBehavior" receiveTimeout="00:03:00" openTimeout="00:03:30" closeTimeout="00:03:00" sendTimeout="00:03:00" maxReceivedMessageSize="2147483647">
<security mode="None"/>
<readerQuotas maxArrayLength="2147483647" maxBytesPerRead="2147483647" maxDepth="64" maxStringContentLength="2147483647"/>
</binding>
</netTcpBinding>

希望大神给点意见


-----------------------2017/11/13 15:00:19----------------------------------- ConApp.exe::ConApp.Program->Void CurrentDomain_FirstChanceException(System.Object, System.Runtime.ExceptionServices.FirstChanceExceptionEventArgs)

System.Net.Sockets.SocketException (0x80004005): The I/O operation has been aborted because of either a thread exit or an application request
at System.ServiceModel.Channels.SocketConnection.HandleReceiveAsyncCompleted() ;
----------------------------------------------------------------

-----------------------2017/11/13 15:00:20----------------------------------- ConApp.exe::ConApp.Program->Void CurrentDomain_FirstChanceException(System.Object, System.Runtime.ExceptionServices.FirstChanceExceptionEventArgs)

System.TimeoutException: The socket was aborted because an asynchronous receive from the socket did not complete 00:02:00. The time allotted to this operation may have been a portion of a longer timeout. ---> System.Net.Sockets.SocketException: The I/O operation has been aborted because of either a thread exit or an application request
at System.ServiceModel.Channels.SocketConnection.HandleReceiveAsyncCompleted()
at System.ServiceModel.Channels.SocketConnection.OnReceiveAsync(Object sender, SocketAsyncEventArgs eventArgs)
--- End of inner exception stack trace ---
at System.ServiceModel.Channels.SocketConnection.EndRead() ;
----------------------------------------------------------------
...全文
150 1 打赏 收藏 转发到动态 举报
写回复
用AI写文章
1 条回复
切换为时间正序
请发表友善的回复…
发表回复

110,533

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术 C#
社区管理员
  • C#
  • Web++
  • by_封爱
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

让您成为最强悍的C#开发者

试试用AI创作助手写篇文章吧