开发者

how to check availablity of wcf service client for callback?

I've implemented pub/sub framework using ASP.NET, WCF Service with net.tcp binding. I hosted wcf service on IIS7.5. My code was developed under VS2010, Windows7.

My demo application is working fine but I just want to handle the error exception when my wcf service callback to client.

So far, my WCF Service or ASP.NET did not throw any error to screen at all.

here is my step of testing:

  1. started service

  2. opened 2 IE (e.g. UserA and UserB)

  3. both User subscribed to WCF Service

  4. closed UserB (closed IE of B)

  5. tried to send msg from UserA to UserB

  6. UserA could send msg to B but no error was appeared

I expected that it should be some error appear to my face but no...

开发者_运维百科please suggest me how to handle this case?

Thank you


The connection/client lives in IIS on that machine, not your browser. Closing IE will not necessarily close the client instance, meaning the callback will still succeed. If you want to tie the instance to IE, you need to use something like Silverlight to host the callback functionality. Then you should be able to see the behavior you are looking for.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜