5
votes

I am having a WCF duplex service with Silverlight client and .NET 3.5 WCF service.

The scenario I have is: during the duplex push OneWay operation from server to client if an exception happens in client notification handler the channel gets silently faulted so any further duplex calls from server timeout and fail. (As explained here One-Way Operations and Exceptions)

My question(s):

  1. Can I just decorate with FaultContract a OneWay OperationContract, wrap the exception on client and prevent faulting of the channel?
  2. if not, what would be some other way to catch the exception which occurred on the client during the duplex push from server?
1
This needs an answer. =[Langdon

1 Answers

0
votes

When you use OneWay OperationContract, the receiver should not reply nor the sender of the request should expect one.

  1. You can't.
  2. Your best bet is you can create another OneWay OperationContract between client and the service so that the service can send the fault to the client.