开发者

In WCF, does a timeout fault the channel?

开发者 https://www.devze.com 2022-12-27 05:04 出处:网络
In WCF, does a timeout on a request-response operation fault the channel at the client\'s end? If a server times out when sending a response, is t开发者_JS百科he channel faulted at the server\'s end?

In WCF, does a timeout on a request-response operation fault the channel at the client's end?

If a server times out when sending a response, is t开发者_JS百科he channel faulted at the server's end?


Yes, a timeout will fault the channel - and there's always only one channel linking a client and a server - the server doesn't have a channel of its own...

You basically have:

+-----------+                       +-----------+
|           |_______________________|           |
|  Client   |     The Channel       |  Server   |
|           |-----------------------|           |
+-----------+                       +-----------+

There's really only one channel which connects the two bits. As for timeouts - if both ends define a different value for the same timeout, the smaller value will "win" and become relevant - the higher value (on the other end) isn't taken into account.


Correct, the timeout will fault the channel. You can set the max timeout time on both the client and the server side.


It depends which Timeout.

If you hit the SendTimeout or ReceiveTimeout of your binding (in my case NetTcpBinding), then yes, the channel will fault.

BUT, if you hit the OperationTimeout of your Service (in my case DuplexChannel) then you will just get a TimeoutException and the channel will NOT fault.

0

精彩评论

暂无评论...
验证码 换一张
取 消