开发者

Monotouch - WCF Binding Timeouts not being obeyed

开发者 https://www.devze.com 2023-02-27 02:37 出处:网络
A service is created via the Silverlight service console program \"slsvcutil\" We use this generated code and set timeouts, but the timeouts are not being obeyed. We have them set to 5 s开发者_C百科e

A service is created via the Silverlight service console program "slsvcutil"

We use this generated code and set timeouts, but the timeouts are not being obeyed. We have them set to 5 s开发者_C百科econds, but the client doesn;t time out for over a minute (default)

svc = new MyServiceClient (........);
svc.Endpoint.Binding.OpenTimeout = Settings.TimeOutServiceOpen;
svc.Endpoint.Binding.CloseTimeout = Settings.TimeOutServiceClose;
svc.Endpoint.Binding.ReceiveTimeout = Settings.TimeOutServiceRecieve;
svc.Endpoint.Binding.SendTimeout = Settings.TimeOutServiceSend;


Appears to be a bug. Bug has been submitted to Monotouch team.


Use this instead:

svc.InnerChannel.OperationTimeout = ....

This seems to work for me.

0

精彩评论

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